diff options
author | Bin Yang <bin.yang@windriver.com> | 2019-04-15 08:43:41 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-04-15 08:43:41 +0000 |
commit | e3e4aaf2140c94fe0811c40186df2f860a2346d7 (patch) | |
tree | 8e6c3c0f5e4e8b61147d726f41f457e933354e3b /artifactbroker/main/src/test/resources/parameters | |
parent | 2faa774836fc4e2bc7a85091a8c832c2bc5415d2 (diff) | |
parent | dc1321b4c135242c67e94f5af57d0e39866ce2d8 (diff) |
Merge "add testcase to improve test coverage"
Diffstat (limited to 'artifactbroker/main/src/test/resources/parameters')
10 files changed, 381 insertions, 2 deletions
diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyArtifactForwarder.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyArtifactForwarder.json new file mode 100644 index 0000000..4318c1e --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyArtifactForwarder.json @@ -0,0 +1,43 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"DummyReceptionHandler", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandler.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandler.json index c1535e0..39a04d8 100644 --- a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandler.json +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandler.json @@ -18,9 +18,9 @@ } } }, - "policyForwarderConfigurationParameters":{ + "artifactForwarderConfigurationParameters":{ "dummyConfiguration":{ - "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyPolicyForwarderParameterGroup", + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", "parameters":{ "useHttps": false, "hostname": "192.168.99.100", diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandlerClass.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandlerClass.json new file mode 100644 index 0000000..099de71 --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_EmptyReceptionHandlerClass.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.InvalidSdcReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationName": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidForwarderConfigurationClassName.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidForwarderConfigurationClassName.json new file mode 100644 index 0000000..b70fdaa --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidForwarderConfigurationClassName.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"DummyReceptionHandler", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationParameters": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidName.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidName.json new file mode 100644 index 0000000..6bbecad --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidName.json @@ -0,0 +1,48 @@ +{ + "name":" ", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"DummyReceptionHandler", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationName": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerClass.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerClass.json new file mode 100644 index 0000000..2def59a --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerClass.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.InvalidSdcReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationName": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.InvalidReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerParameters.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerParameters.json new file mode 100644 index 0000000..d3ad8b2 --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidReceptionHandlerParameters.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.InvalidSdcReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationName": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidRestServerParameters.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidRestServerParameters.json new file mode 100644 index 0000000..a37ca47 --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_InvalidRestServerParameters.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"", + "port":-1, + "userName":"", + "password":"" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"DummyReceptionHandler", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationName": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarderParameterGroup", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_NoPolicyForwarder.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_NoArtifactForwarder.json index abd0d6d..abd0d6d 100644 --- a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_NoPolicyForwarder.json +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_NoArtifactForwarder.json diff --git a/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_UnknownForwarderConfigurationClassName.json b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_UnknownForwarderConfigurationClassName.json new file mode 100644 index 0000000..2bde3c0 --- /dev/null +++ b/artifactbroker/main/src/test/resources/parameters/DistributionConfigParameters_UnknownForwarderConfigurationClassName.json @@ -0,0 +1,48 @@ +{ + "name":"SDCDistributionGroup", + "restServerParameters":{ + "host":"0.0.0.0", + "port":6969, + "userName":"healthcheck", + "password":"zb!XztG34" + }, + "receptionHandlerParameters":{ + "DummyReceptionHandler":{ + "receptionHandlerType":"DummyReceptionHandler", + "receptionHandlerClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandler", + "receptionHandlerConfigurationName":"dummyReceptionHandlerConfiguration", + "pluginHandlerParameters":{ + "artifactForwarders":{ + "DummyForwarder":{ + "forwarderType":"DummyForwarder", + "forwarderClassName":"org.onap.policy.distribution.main.testclasses.DummyArtifactForwarder", + "forwarderConfigurationParameters": "dummyConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "dummyReceptionHandlerConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.main.testclasses.DummyReceptionHandlerParameterGroup", + "parameters":{ + "myStringParameter": "stringValue", + "myIntegerParameter":20, + "myBooleanParameter": true + } + } + }, + "artifactForwarderConfigurationParameters":{ + "dummyConfiguration":{ + "parameterClassName":"org.onap.policy.Unknown", + "parameters":{ + "useHttps": false, + "hostname": "192.168.99.100", + "port": 8081, + "userName": "user", + "password": "pw123", + "isManaged": true + } + } + } +} |