diff options
author | 2019-07-18 11:52:22 +0000 | |
---|---|---|
committer | 2019-07-18 11:52:22 +0000 | |
commit | 597aba038c90ef34a8058794c73a2213d778673e (patch) | |
tree | 991897c614cfd58abaf693793807812e9d11156d /bpmn/so-bpmn-infrastructure-common/src/test/java | |
parent | 7ef379bd727b99c04dd31ec957cb68f1f612905b (diff) | |
parent | cd0fa5da3dd92649adc837ca774459fea2fd08c4 (diff) |
Merge "Vulnerability fixes in ServicePluginFactory"
Diffstat (limited to 'bpmn/so-bpmn-infrastructure-common/src/test/java')
-rw-r--r-- | bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactoryTest.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactoryTest.java b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactoryTest.java index 0b4050beec..1a75f125f6 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactoryTest.java +++ b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactoryTest.java @@ -20,6 +20,7 @@ package org.onap.so.bpmn.infrastructure.workflow.service; import static org.mockito.Mockito.doReturn; +import org.apache.commons.lang.reflect.FieldUtils; import org.junit.Assert; import org.junit.Test; import org.junit.runner.RunWith; @@ -154,4 +155,21 @@ public class ServicePluginFactoryTest { String result = servicePluginFactory.doServiceHoming(null, invalidJsonWithOnlyNeededValues); Assert.assertEquals(result, invalidJsonWithOnlyNeededValues); } + + @Test + public void verifyExternalConfigurationLoading() throws IllegalAccessException { + + ServicePluginFactory servicePluginFactory = ServicePluginFactory.getInstance(); + + String oofDefaultEndpoint = (String) FieldUtils.readField(servicePluginFactory, "OOF_DEFAULT_ENDPOINT", true); + Assert.assertNotNull(oofDefaultEndpoint); + + String thirdSpDefaultEndpoint = + (String) FieldUtils.readField(servicePluginFactory, "THIRD_SP_DEFAULT_ENDPOINT", true); + Assert.assertNotNull(thirdSpDefaultEndpoint); + + String inventoryOssDefaultEndpoint = + (String) FieldUtils.readField(servicePluginFactory, "INVENTORY_OSS_DEFAULT_ENDPOINT", true); + Assert.assertNotNull(inventoryOssDefaultEndpoint); + } } |