summaryrefslogtreecommitdiffstats
path: root/main/src/test/resources
diff options
context:
space:
mode:
authorHOCKLA <ah999m@att.com>2019-11-15 08:52:39 -0600
committerHOCKLA <ah999m@att.com>2019-11-15 11:27:47 -0600
commite53be640b3a4c37dbd841c81b5c467082986c05b (patch)
treef6e90fac68b0d4dd0b845d36cf774c0054494b25 /main/src/test/resources
parent9a093f08a6b3357bdd750c12703ca8f1cd77fc74 (diff)
Changed Xacml-pdp to report pdp group defined in XacmlPdpParameters config file
Ignore the pdp group specified in the PdpUpdate message. Updated junits and test resources. Issue-ID: POLICY-2229 Change-Id: I0c7a33c45424cef6440b0837e1dd22a7487c5d44 Signed-off-by: HOCKLA <ah999m@att.com>
Diffstat (limited to 'main/src/test/resources')
-rw-r--r--main/src/test/resources/expectedValidationResults/InvalidRestServerParameters.txt2
-rw-r--r--main/src/test/resources/parameters/MinimumParameters.json3
-rw-r--r--main/src/test/resources/parameters/XacmlPdpConfigParameters.json3
-rw-r--r--main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidName.json1
-rw-r--r--main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidPdpGroup.json30
-rw-r--r--main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json3
-rw-r--r--main/src/test/resources/parameters/XacmlPdpConfigParameters_Std.json3
7 files changed, 40 insertions, 5 deletions
diff --git a/main/src/test/resources/expectedValidationResults/InvalidRestServerParameters.txt b/main/src/test/resources/expectedValidationResults/InvalidRestServerParameters.txt
index 957da6d6..1a5187b3 100644
--- a/main/src/test/resources/expectedValidationResults/InvalidRestServerParameters.txt
+++ b/main/src/test/resources/expectedValidationResults/InvalidRestServerParameters.txt
@@ -1,5 +1,5 @@
validation error(s) on parameters from "parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json"
-parameter group "XacmlPdpGroup" type "org.onap.policy.pdpx.main.parameters.XacmlPdpParameterGroup" INVALID, parameter group has status INVALID
+parameter group "XacmlPdpParameters" type "org.onap.policy.pdpx.main.parameters.XacmlPdpParameterGroup" INVALID, parameter group has status INVALID
parameter group "null" type "org.onap.policy.pdpx.main.parameters.RestServerParameters" INVALID, parameter group has status INVALID
field "host" type "java.lang.String" value "" INVALID, must be a non-blank string containing hostname/ipaddress of the xacml pdp rest server
field "port" type "int" value "-1" INVALID, must be a positive integer containing port of the xacml pdp rest server
diff --git a/main/src/test/resources/parameters/MinimumParameters.json b/main/src/test/resources/parameters/MinimumParameters.json
index 42e54581..e547e7ee 100644
--- a/main/src/test/resources/parameters/MinimumParameters.json
+++ b/main/src/test/resources/parameters/MinimumParameters.json
@@ -1,5 +1,6 @@
{
- "name": "XacmlPdpGroup",
+ "name":"XacmlPdpParameters",
+ "pdpGroup": "XacmlPdpGroup",
"restServerParameters": {
"host": "0.0.0.0",
"port": 6969,
diff --git a/main/src/test/resources/parameters/XacmlPdpConfigParameters.json b/main/src/test/resources/parameters/XacmlPdpConfigParameters.json
index 186a7b26..5d0a103c 100644
--- a/main/src/test/resources/parameters/XacmlPdpConfigParameters.json
+++ b/main/src/test/resources/parameters/XacmlPdpConfigParameters.json
@@ -1,5 +1,6 @@
{
- "name": "XacmlPdpGroup",
+ "name": "XacmlPdpParameters",
+ "pdpGroup": "XacmlPdpGroup",
"restServerParameters": {
"host": "0.0.0.0",
"port": 6969,
diff --git a/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidName.json b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidName.json
index 27e7ef46..dcc5cd93 100644
--- a/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidName.json
+++ b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidName.json
@@ -1,5 +1,6 @@
{
"name": " ",
+ "pdpGroup": "XacmlPdpGroup",
"restServerParameters":{
"host":"0.0.0.0",
"port": 6969,
diff --git a/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidPdpGroup.json b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidPdpGroup.json
new file mode 100644
index 00000000..18e486d5
--- /dev/null
+++ b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidPdpGroup.json
@@ -0,0 +1,30 @@
+{
+ "name": "XacmlPdpParameters",
+ "pdpGroup": " ",
+ "restServerParameters":{
+ "host":"0.0.0.0",
+ "port": 6969,
+ "userName":"healthcheck",
+ "password":"zb!XztG34",
+ "https":true
+ },
+ "policyApiParameters": {
+ "host": "0.0.0.0",
+ "port": 6970,
+ "userName": "healthcheck",
+ "password": "zb!XztG34"
+ },
+ "applicationPath": "src/test/resources/apps",
+ "topicParameterGroup": {
+ "topicSources" : [{
+ "topic" : "POLICY-PDP-PAP",
+ "servers" : [ "anyserver" ],
+ "topicCommInfrastructure" : "noop"
+ }],
+ "topicSinks" : [{
+ "topic" : "POLICY-PDP-PAP",
+ "servers" : [ "anyserver" ],
+ "topicCommInfrastructure" : "noop"
+ }]
+ }
+} \ No newline at end of file
diff --git a/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json
index d320b11d..4aad68b2 100644
--- a/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json
+++ b/main/src/test/resources/parameters/XacmlPdpConfigParameters_InvalidRestServerParameters.json
@@ -1,5 +1,6 @@
{
- "name": "XacmlPdpGroup",
+ "name":"XacmlPdpParameters",
+ "pdpGroup": "XacmlPdpGroup",
"restServerParameters": {
"host": "",
"port": -1,
diff --git a/main/src/test/resources/parameters/XacmlPdpConfigParameters_Std.json b/main/src/test/resources/parameters/XacmlPdpConfigParameters_Std.json
index 1c17414b..3f9e6cb1 100644
--- a/main/src/test/resources/parameters/XacmlPdpConfigParameters_Std.json
+++ b/main/src/test/resources/parameters/XacmlPdpConfigParameters_Std.json
@@ -1,5 +1,6 @@
{
- "name":"XacmlPdpGroup",
+ "name":"XacmlPdpParameters",
+ "pdpGroup": "XacmlPdpGroup",
"restServerParameters":{
"host":"0.0.0.0",
"port":${port},