From a84ef3cb2133fde745c50d7a23290505e4f4659a Mon Sep 17 00:00:00 2001 From: Jim Hahn Date: Thu, 2 Sep 2021 09:57:16 -0400 Subject: Fix eclipse warnings in clamp Fixed some of these warnings, just in policy-clamp-runtime: - equals() with wrong argument type in junit - remove unneeded "SuppressWarning" - unused fields - deprecated classes/methods Fixed some sonars, too: - use isEqualByComparingTo() - method complexity: used eclipse to auto-extract methods Fixed checkstyle issues: - indentation level Did not address all deprecation issues (e.g., SSLSocketFactory). Issue-ID: POLICY-3200 Change-Id: Ibd92e5326854002dc0ca2d7b3b777699cafb5e98 Signed-off-by: Jim Hahn --- .../instantiation/ControlLoopInstantiationProviderTest.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'runtime-controlloop/src/test/java') diff --git a/runtime-controlloop/src/test/java/org/onap/policy/clamp/controlloop/runtime/instantiation/ControlLoopInstantiationProviderTest.java b/runtime-controlloop/src/test/java/org/onap/policy/clamp/controlloop/runtime/instantiation/ControlLoopInstantiationProviderTest.java index f136b9f10..7f04056cf 100644 --- a/runtime-controlloop/src/test/java/org/onap/policy/clamp/controlloop/runtime/instantiation/ControlLoopInstantiationProviderTest.java +++ b/runtime-controlloop/src/test/java/org/onap/policy/clamp/controlloop/runtime/instantiation/ControlLoopInstantiationProviderTest.java @@ -246,8 +246,8 @@ class ControlLoopInstantiationProviderTest { new ControlLoopInstantiationProvider(clProvider, commissioningProvider, supervisionHandler); assertThatThrownBy( - () -> instantiationProvider.deleteControlLoop(controlLoop0.getName(), controlLoop0.getVersion())) - .hasMessageMatching(CONTROL_LOOP_NOT_FOUND); + () -> instantiationProvider.deleteControlLoop(controlLoop0.getName(), controlLoop0.getVersion())) + .hasMessageMatching(CONTROL_LOOP_NOT_FOUND); InstantiationUtils.assertInstantiationResponse(instantiationProvider.createControlLoops(controlLoops), controlLoops); @@ -282,8 +282,8 @@ class ControlLoopInstantiationProviderTest { instantiationProvider.updateControlLoops(controlLoops); assertThatThrownBy( - () -> instantiationProvider.deleteControlLoop(controlLoop.getName(), controlLoop.getVersion())) - .hasMessageMatching(String.format(DELETE_BAD_REQUEST, state)); + () -> instantiationProvider.deleteControlLoop(controlLoop.getName(), controlLoop.getVersion())) + .hasMessageMatching(String.format(DELETE_BAD_REQUEST, state)); } @Test -- cgit 1.2.3-korg