diff options
author | adheli.tavares <adheli.tavares@est.tech> | 2024-04-02 15:15:39 +0100 |
---|---|---|
committer | adheli.tavares <adheli.tavares@est.tech> | 2024-04-10 13:39:24 +0100 |
commit | 22afe401ca130eba6543f740039e8a3c13d11861 (patch) | |
tree | fd15c592ed84dd364757ccecd67438a9d2fe58b4 /models-sim | |
parent | 389c85c8e7213c10c17896f4c63d94e2b5e9d27a (diff) |
Dependency management update
- including dependencies to pom.xml files only where they are used,
avoiding extra dependencies being added in all packages.
Issue-ID: POLICY-4945
Change-Id: I85b18befe3fe2877c754b1ac818d1b4994f9f7f9
Signed-off-by: adheli.tavares <adheli.tavares@est.tech>
Diffstat (limited to 'models-sim')
6 files changed, 32 insertions, 30 deletions
diff --git a/models-sim/policy-models-sim-pdp/pom.xml b/models-sim/policy-models-sim-pdp/pom.xml index a9532270d..601c81f83 100644 --- a/models-sim/policy-models-sim-pdp/pom.xml +++ b/models-sim/policy-models-sim-pdp/pom.xml @@ -1,7 +1,7 @@ <!-- ============LICENSE_START======================================================= Copyright (C) 2019 Bell Canada. All rights reserved. - Modifications Copyright (C) 2023 Nordix Foundation. + Modifications Copyright (C) 2023-2024 Nordix Foundation. ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -51,13 +51,18 @@ <groupId>org.onap.policy.common</groupId> <artifactId>utils-test</artifactId> <version>${policy.common.version}</version> + <scope>test</scope> </dependency> - <dependency> <groupId>org.onap.policy.common</groupId> <artifactId>common-parameters</artifactId> <version>${policy.common.version}</version> </dependency> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <scope>test</scope> + </dependency> </dependencies> <build> <resources> @@ -99,6 +104,5 @@ </executions> </plugin> </plugins> - </build> </project> diff --git a/models-sim/policy-models-sim-pdp/src/test/java/org/onap/policy/models/sim/pdp/parameters/TestPdpSimulatorParameterHandler.java b/models-sim/policy-models-sim-pdp/src/test/java/org/onap/policy/models/sim/pdp/parameters/TestPdpSimulatorParameterHandler.java index 03c73cceb..84c7b0d5f 100644 --- a/models-sim/policy-models-sim-pdp/src/test/java/org/onap/policy/models/sim/pdp/parameters/TestPdpSimulatorParameterHandler.java +++ b/models-sim/policy-models-sim-pdp/src/test/java/org/onap/policy/models/sim/pdp/parameters/TestPdpSimulatorParameterHandler.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2019-2021 Nordix Foundation. + * Copyright (C) 2019-2021, 2024 Nordix Foundation. * Modifications Copyright (C) 2019, 2021 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); @@ -41,7 +41,7 @@ import org.onap.policy.models.sim.pdp.exception.PdpSimulatorException; public class TestPdpSimulatorParameterHandler { @Test - public void testParameterHandlerNoParameterFile() throws PdpSimulatorException, CommandLineException { + public void testParameterHandlerNoParameterFile() throws CommandLineException { final String[] emptyArgumentString = { "-c", "src/test/resources/NoParametersFile.json" }; final PdpSimulatorCommandLineArguments emptyArguments = new PdpSimulatorCommandLineArguments(); @@ -57,7 +57,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testParameterHandlerEmptyParameters() throws PdpSimulatorException, CommandLineException { + public void testParameterHandlerEmptyParameters() throws CommandLineException { final String[] noArgumentString = { "-c", "src/test/resources/NoParameters.json" }; final PdpSimulatorCommandLineArguments noArguments = new PdpSimulatorCommandLineArguments(); @@ -68,7 +68,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testParameterHandlerInvalidParameters() throws PdpSimulatorException, CommandLineException { + public void testParameterHandlerInvalidParameters() throws CommandLineException { final String[] invalidArgumentString = { "-c", "src/test/resources/InvalidParameters.json" }; final PdpSimulatorCommandLineArguments invalidArguments = new PdpSimulatorCommandLineArguments(); @@ -80,7 +80,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testParameterHandlerNoParameters() throws PdpSimulatorException, CommandLineException { + public void testParameterHandlerNoParameters() throws CommandLineException { final String[] noArgumentString = { "-c", "src/test/resources/EmptyConfigParameters.json" }; final PdpSimulatorCommandLineArguments noArguments = new PdpSimulatorCommandLineArguments(); @@ -103,7 +103,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testPdpSimulatorParameterGroup_InvalidName() throws PdpSimulatorException, CommandLineException { + public void testPdpSimulatorParameterGroup_InvalidName() throws CommandLineException { final String[] pdpSimulatorConfigParameters = {"-c", "src/test/resources/PdpSimulatorConfigParameters_InvalidName.json"}; @@ -115,7 +115,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testPdpSimulatorVersion() throws PdpSimulatorException, CommandLineException { + public void testPdpSimulatorVersion() throws CommandLineException { final String[] pdpSimulatorConfigParameters = { "-v" }; final PdpSimulatorCommandLineArguments arguments = new PdpSimulatorCommandLineArguments(); final String version = arguments.parse(pdpSimulatorConfigParameters); @@ -123,7 +123,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testPdpSimulatorHelp() throws PdpSimulatorException, CommandLineException { + public void testPdpSimulatorHelp() throws CommandLineException { final String[] pdpSimulatorConfigParameters = { "-h" }; final PdpSimulatorCommandLineArguments arguments = new PdpSimulatorCommandLineArguments(); final String help = arguments.parse(pdpSimulatorConfigParameters); @@ -140,7 +140,7 @@ public class TestPdpSimulatorParameterHandler { } @Test - public void testPdpSimulatorProperty() throws PdpSimulatorException, CommandLineException { + public void testPdpSimulatorProperty() throws CommandLineException { final String[] pdpSimulatorConfigParameters = { "-p", "dummyProperties.json" }; final PdpSimulatorCommandLineArguments arguments = new PdpSimulatorCommandLineArguments(); arguments.parse(pdpSimulatorConfigParameters); diff --git a/models-sim/policy-models-sim-pdp/src/test/resources/PdpSimulatorConfigParameters.json b/models-sim/policy-models-sim-pdp/src/test/resources/PdpSimulatorConfigParameters.json index 6c6068dd3..bacb4de86 100644 --- a/models-sim/policy-models-sim-pdp/src/test/resources/PdpSimulatorConfigParameters.json +++ b/models-sim/policy-models-sim-pdp/src/test/resources/PdpSimulatorConfigParameters.json @@ -9,10 +9,6 @@ }, "topicParameterGroup": { "topicSources" : [ { - "topic" : "ueb-source", - "servers" : [ "my-server" ], - "topicCommInfrastructure" : "ueb" - },{ "topic" : "POLICY-PDP-PAP1", "servers" : [ "message-router1, message-router2" ], "topicCommInfrastructure" : "NOOP" @@ -22,10 +18,6 @@ "topicCommInfrastructure" : "NOOP" }], "topicSinks" : [ { - "topic" : "ueb-sink", - "servers" : [ "my-server" ], - "topicCommInfrastructure" : "ueb" - },{ "topic" : "POLICY-PDP-PAP2", "servers" : [ "message-router1, message-router2" ], "topicCommInfrastructure" : "NOOP" diff --git a/models-sim/policy-models-sim-pdp/src/test/resources/TestConfigParameters.json b/models-sim/policy-models-sim-pdp/src/test/resources/TestConfigParameters.json index b114dd1fd..1ea5bfc4e 100644 --- a/models-sim/policy-models-sim-pdp/src/test/resources/TestConfigParameters.json +++ b/models-sim/policy-models-sim-pdp/src/test/resources/TestConfigParameters.json @@ -9,10 +9,6 @@ }, "topicParameterGroup": { "topicSources" : [ { - "topic" : "ueb-source", - "servers" : [ "my-server" ], - "topicCommInfrastructure" : "ueb" - },{ "topic" : "POLICY-PDP-PAP1", "servers" : [ "message-router1, message-router2" ], "topicCommInfrastructure" : "NOOP" @@ -22,10 +18,6 @@ "topicCommInfrastructure" : "NOOP" }], "topicSinks" : [ { - "topic" : "ueb-sink", - "servers" : [ "my-server" ], - "topicCommInfrastructure" : "ueb" - },{ "topic" : "POLICY-PDP-PAP2", "servers" : [ "message-router1, message-router2" ], "topicCommInfrastructure" : "NOOP" diff --git a/models-sim/policy-models-simulators/pom.xml b/models-sim/policy-models-simulators/pom.xml index 360591052..ed5a31977 100644 --- a/models-sim/policy-models-simulators/pom.xml +++ b/models-sim/policy-models-simulators/pom.xml @@ -3,7 +3,7 @@ ONAP ================================================================================ Copyright (C) 2020-2021 AT&T Intellectual Property. All rights reserved. - Modifications Copyright (C) 2023 Nordix Foundation. + Modifications Copyright (C) 2023-2024 Nordix Foundation. ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -42,5 +42,20 @@ <artifactId>simulators</artifactId> <version>${project.version}</version> </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-fips</artifactId> + </dependency> + <dependency> + <groupId>org.onap.policy.common</groupId> + <artifactId>utils-test</artifactId> + <version>${policy.common.version}</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <scope>test</scope> + </dependency> </dependencies> </project> diff --git a/models-sim/policy-models-simulators/src/main/java/org/onap/policy/models/simulators/Main.java b/models-sim/policy-models-simulators/src/main/java/org/onap/policy/models/simulators/Main.java index 1951ea3c5..ce32fd407 100644 --- a/models-sim/policy-models-simulators/src/main/java/org/onap/policy/models/simulators/Main.java +++ b/models-sim/policy-models-simulators/src/main/java/org/onap/policy/models/simulators/Main.java @@ -33,7 +33,6 @@ import org.onap.policy.common.endpoints.http.server.HttpServletServer; import org.onap.policy.common.endpoints.http.server.HttpServletServerFactoryInstance; import org.onap.policy.common.endpoints.properties.PolicyEndPointProperties; import org.onap.policy.common.gson.GsonMessageBodyHandler; -import org.onap.policy.common.parameters.BeanValidationResult; import org.onap.policy.common.utils.coder.Coder; import org.onap.policy.common.utils.coder.CoderException; import org.onap.policy.common.utils.coder.StandardCoder; |