diff options
author | liamfallon <liam.fallon@est.tech> | 2019-04-08 17:30:54 +0000 |
---|---|---|
committer | liamfallon <liam.fallon@est.tech> | 2019-04-08 17:30:54 +0000 |
commit | 0b15f3bf60162a62505593186737bca98bd4349c (patch) | |
tree | 0935b5d9321c9a988256741309d9dfdb688f4521 /models-pdp/src/test/resources | |
parent | a32b49c3ec54e5f3bf23634a5fb538909905f8e6 (diff) |
Add lists and tests for PDP filters
The policy type and policy filters for PDP groups are added
in this review.
Also filter tests for PDP group filter is completed.
Issue-ID: POLICY-1095
Change-Id: Ia28776c809f2ab879af4007b3480621637a83f69
Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'models-pdp/src/test/resources')
-rw-r--r-- | models-pdp/src/test/resources/testdata/PdpGroupsForFiltering.json | 287 |
1 files changed, 248 insertions, 39 deletions
diff --git a/models-pdp/src/test/resources/testdata/PdpGroupsForFiltering.json b/models-pdp/src/test/resources/testdata/PdpGroupsForFiltering.json index c62e1ea58..623ee4e23 100644 --- a/models-pdp/src/test/resources/testdata/PdpGroupsForFiltering.json +++ b/models-pdp/src/test/resources/testdata/PdpGroupsForFiltering.json @@ -1,73 +1,133 @@ { - "groups": [ + "groups": + [ { "name": "PdpGroup0", "version": "1.2.3", "description": "group description", "pdpGroupState": "PASSIVE", - "properties": { + "properties": + { "groupProperty0": "Value of Group Property 0" }, - "pdpSubgroups": [ + + "pdpSubgroups": + [ { "pdpType": "APEX", - "supportedPolicyTypes": [ + "supportedPolicyTypes": + [ { "name": "policy.type.0", "version": "1.2.3" + }, + { + "name": "policy.type.1", + "version": "4.5.6" + }, + { + "name": "policy.type.2", + "version": "7.8.9" } ], - "policies": [ + + "policies": + [ { "name": "Policy0", "version": "4.5.6" + }, + { + "name": "Policy1", + "version": "4.5.6" } ], + "currentInstanceCount": 123, "desiredInstanceCount": 456, - "properties": { + "properties": + { "subgroupProperty0": "Value of sub Group Property 0" }, - "pdpInstances": [ + + "pdpInstances": + [ { "instanceId": "apex-0", "pdpState": "ACTIVE", "healthy": "NOT_HEALTHY", "message": "message from PDP" + }, + { + "instanceId": "apex-0", + "pdpState": "PASSIVE", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" + }, + { + "instanceId": "apex-0", + "pdpState": "SAFE", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" + }, + { + "instanceId": "apex-0", + "pdpState": "TEST", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" } ] } ] }, + { "name": "PdpGroup0", "version": "1.2.4", "description": "group description", - "pdpGroupState": "PASSIVE", - "properties": { + "pdpGroupState": "ACTIVE", + "properties": + { "groupProperty0": "Value of Group Property 0" }, - "pdpSubgroups": [ + + "pdpSubgroups": + [ { "pdpType": "APEX", - "supportedPolicyTypes": [ + "supportedPolicyTypes": + [ { "name": "policy.type.0", "version": "1.2.3" + }, + { + "name": "policy.type.1", + "version": "4.5.6" + }, + { + "name": "policy.type.3", + "version": "0.1.2" } ], - "policies": [ + + "policies": + [ { - "name": "Policy0", + "name": "Policy2", "version": "4.5.6" } ], + "currentInstanceCount": 123, "desiredInstanceCount": 456, - "properties": { + "properties": + { "subgroupProperty0": "Value of sub Group Property 0" }, - "pdpInstances": [ + + "pdpInstances": + [ { "instanceId": "apex-0", "pdpState": "ACTIVE", @@ -78,38 +138,92 @@ } ] }, + { "name": "PdpGroup0", "version": "1.2.1", "description": "group description", - "pdpGroupState": "PASSIVE", - "properties": { + "pdpGroupState": "SAFE", + "properties": + { "groupProperty0": "Value of Group Property 0" }, - "pdpSubgroups": [ + + "pdpSubgroups": + [ { "pdpType": "APEX", - "supportedPolicyTypes": [ + "supportedPolicyTypes": + [ + { + "name": "policy.type.1", + "version": "4.5.6" + }, + { + "name": "policy.type.3", + "version": "0.1.2" + } + ], + + "policies": + [ + { + "name": "Policy2", + "version": "4.5.6" + }, + { + "name": "Policy3", + "version": "1.2.3" + } + ], + + "currentInstanceCount": 123, + "desiredInstanceCount": 456, + "properties": + { + "subgroupProperty0": "Value of sub Group Property 0" + }, + + "pdpInstances": + [ + { + "instanceId": "apex-0", + "pdpState": "SAFE", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" + } + ] + }, + { + "pdpType": "DROOLS", + "supportedPolicyTypes": + [ { "name": "policy.type.0", "version": "1.2.3" } ], - "policies": [ + + "policies": + [ { "name": "Policy0", "version": "4.5.6" } ], + "currentInstanceCount": 123, "desiredInstanceCount": 456, - "properties": { + "properties": + { "subgroupProperty0": "Value of sub Group Property 0" }, - "pdpInstances": [ + + "pdpInstances": + [ { "instanceId": "apex-0", - "pdpState": "ACTIVE", + "pdpState": "SAFE", "healthy": "NOT_HEALTHY", "message": "message from PDP" } @@ -122,33 +236,47 @@ "version": "1.2.1", "description": "group description", "pdpGroupState": "PASSIVE", - "properties": { + "properties": + { "groupProperty0": "Value of Group Property 0" }, - "pdpSubgroups": [ + + "pdpSubgroups": + [ { "pdpType": "APEX", - "supportedPolicyTypes": [ + "supportedPolicyTypes": + [ { - "name": "policy.type.0", - "version": "1.2.3" + "name": "policy.type.1", + "version": "4.5.6" + }, + { + "name": "policy.type.2", + "version": "7.8.9" } ], - "policies": [ + + "policies": + [ { "name": "Policy0", "version": "4.5.6" } ], + "currentInstanceCount": 123, "desiredInstanceCount": 456, - "properties": { + "properties": + { "subgroupProperty0": "Value of sub Group Property 0" }, - "pdpInstances": [ + + "pdpInstances": + [ { "instanceId": "apex-0", - "pdpState": "ACTIVE", + "pdpState": "PASSIVE", "healthy": "NOT_HEALTHY", "message": "message from PDP" } @@ -156,35 +284,116 @@ } ] }, + { "name": "PdpGroup1", "version": "1.2.3", "description": "group description", - "pdpGroupState": "PASSIVE", - "properties": { + "pdpGroupState": "TEST", + "properties": + { "groupProperty0": "Value of Group Property 0" }, - "pdpSubgroups": [ + + "pdpSubgroups": + [ { "pdpType": "APEX", - "supportedPolicyTypes": [ + "supportedPolicyTypes": + [ + { + "name": "policy.type.0", + "version": "1.2.3" + } + ], + + "policies": + [ + { + "name": "Policy0", + "version": "4.5.6" + } + ], + + "currentInstanceCount": 123, + "desiredInstanceCount": 456, + "properties": + { + "subgroupProperty0": "Value of sub Group Property 0" + }, + + "pdpInstances": + [ + { + "instanceId": "apex-0", + "pdpState": "TEST", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" + } + ] + }, + { + "pdpType": "DROOLS", + "supportedPolicyTypes": + [ + { + "name": "policy.type.0", + "version": "1.2.3" + } + ], + + "policies": + [ + { + "name": "Policy0", + "version": "4.5.6" + } + ], + + "currentInstanceCount": 123, + "desiredInstanceCount": 456, + "properties": + { + "subgroupProperty0": "Value of sub Group Property 0" + }, + + "pdpInstances": + [ + { + "instanceId": "apex-0", + "pdpState": "PASSIVE", + "healthy": "NOT_HEALTHY", + "message": "message from PDP" + } + ] + }, + { + "pdpType": "XACML", + "supportedPolicyTypes": + [ { "name": "policy.type.0", "version": "1.2.3" } ], - "policies": [ + + "policies": + [ { "name": "Policy0", "version": "4.5.6" } ], + "currentInstanceCount": 123, "desiredInstanceCount": 456, - "properties": { + "properties": + { "subgroupProperty0": "Value of sub Group Property 0" }, - "pdpInstances": [ + + "pdpInstances": + [ { "instanceId": "apex-0", "pdpState": "ACTIVE", |