You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by "jgoodyear (via GitHub)" <gi...@apache.org> on 2024/05/29 19:12:55 UTC
[PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
jgoodyear opened a new pull request, #1901:
URL: https://github.com/apache/cxf/pull/1901
(no comment)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on PR #1901:
URL: https://github.com/apache/cxf/pull/1901#issuecomment-2140953910
@jgoodyear thanks for working on tests, I believe we should spend a bit more time on crafting more or less realistic test cases, may be under `systests/*` even if needed. The ones here clearly use too much mocking (sometimes it is useful) but really shouldn't, plus there is quite large overlap with `systests/*` that I think we should take into account. Hope it makes sense, thank you.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621488452
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
CXF is quite old and some decisions as well, but we should not add tests for a sake of tests or/and coverage, it adds significant maintenance costs for no benefits (surely, in context of CXF).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "jgoodyear (via GitHub)" <gi...@apache.org>.
jgoodyear commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621483140
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
Feels odd to have classes tested outside of the package, even to have some basic smoke testing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on PR #1901:
URL: https://github.com/apache/cxf/pull/1901#issuecomment-2166626863
Relevant code coverage: https://sonarcloud.io/component_measures?metric=coverage&selected=cxf%3Acore%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fcxf%2Fbus%2Fmanagers&id=cxf
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1645104187
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
Review Comment:

--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621492853
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
If you don't mind, let's spend some time and find the gaps, fe. I have not found any tests for `ClientLifeCycleManagerImpl` but you added one (thank again for it), there could be others
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "jgoodyear (via GitHub)" <gi...@apache.org>.
jgoodyear commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621495449
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
Take any portion of the PR you see value in retaining :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1645107739
##########
core/src/test/java/org/apache/cxf/bus/managers/ClientLifeCycleManagerImplTest.java:
##########
Review Comment:

--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621492853
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
If you don't mind, let's spend some time and find the gaps, fe. I have not find any tests for `ClientLifeCycleManagerImpl` but you added one (thank again for it), there could be others
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "jgoodyear (via GitHub)" <gi...@apache.org>.
jgoodyear commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621490511
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
Right on.
Shall CXF-9023 & CXF-9024 be closed as 'will not fix'?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [CXF-9023] Increase unit test coverage on org.apache.cxf.bus [cxf]
Posted by "reta (via GitHub)" <gi...@apache.org>.
reta commented on code in PR #1901:
URL: https://github.com/apache/cxf/pull/1901#discussion_r1621479957
##########
core/src/test/java/org/apache/cxf/bus/ManagedBusTest.java:
##########
@@ -0,0 +1,67 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.bus;
+
+import javax.management.ObjectName;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+
+import org.junit.Before;
+import org.junit.Test;
+
+import static org.junit.Assert.assertEquals;
+
+public class ManagedBusTest {
Review Comment:
@jgoodyear the `ManagedBus` is covered by `ManagedBusTest` (`systests/uncategorized`)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@cxf.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org