diff options
author | liamfallon <liam.fallon@est.tech> | 2019-10-24 21:33:45 -0400 |
---|---|---|
committer | liamfallon <liam.fallon@est.tech> | 2019-10-24 21:50:19 -0400 |
commit | c2ca6ea5cb44103903e1409e8dd6db80167e61e8 (patch) | |
tree | a713b7e2d83a2492d4141881eb886c82a3a10647 /ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java | |
parent | 766f999081e73b301062f1b96bffb9c52d7e9852 (diff) |
CHeckstyle and JUnit for base package in ONAP-REST
Added unit tests and fixed checkstyle and SONAR issues in the base
package of ONAPE-REST
There was a lot of knock-on automatic changes done by Eclipse when I
renamed the class XACMLRestProperties to XacmlRestProperties so ignore
the changes in all but the ONAP-REST package. I also didn't update the
licenses on files on those classes because the changes were automatic.
Issue-ID: POLICY-2131
Change-Id: I28823c844b5192f8d56de76a727996b13e7ea4a6
Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java')
-rw-r--r-- | ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java b/ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java index 822599f13..516d873d4 100644 --- a/ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java +++ b/ONAP-PDP-REST/src/main/java/org/onap/policy/pdp/rest/api/services/PAPServices.java @@ -41,7 +41,7 @@ import org.onap.policy.api.PolicyException; import org.onap.policy.common.logging.flexlogger.FlexLogger; import org.onap.policy.common.logging.flexlogger.Logger; import org.onap.policy.pdp.rest.restauth.AuthenticationService; -import org.onap.policy.rest.XACMLRestProperties; +import org.onap.policy.rest.XacmlRestProperties; import org.onap.policy.utils.PeCryptoUtils; import org.onap.policy.xacml.api.XACMLErrorConstants; import org.onap.policy.xacml.std.pap.StdPDPPolicy; @@ -67,9 +67,9 @@ public class PAPServices { environment = AuthenticationService.getEnvironment(); if (paps == null) { synchronized (papResourceLock) { - String urlList = XACMLProperties.getProperty(XACMLRestProperties.PROP_PAP_URLS); + String urlList = XACMLProperties.getProperty(XacmlRestProperties.PROP_PAP_URLS); if (urlList == null) { - urlList = XACMLProperties.getProperty(XACMLRestProperties.PROP_PAP_URL); + urlList = XACMLProperties.getProperty(XacmlRestProperties.PROP_PAP_URL); } paps = Arrays.asList(urlList.split(",")); } @@ -78,8 +78,8 @@ public class PAPServices { private String getPAPEncoding() { if (encoding == null) { - String userID = XACMLProperties.getProperty(XACMLRestProperties.PROP_PAP_USERID); - String pass = PeCryptoUtils.decrypt(XACMLProperties.getProperty(XACMLRestProperties.PROP_PAP_PASS)); + String userID = XACMLProperties.getProperty(XacmlRestProperties.PROP_PAP_USERID); + String pass = PeCryptoUtils.decrypt(XACMLProperties.getProperty(XacmlRestProperties.PROP_PAP_PASS)); Base64.Encoder encoder = Base64.getEncoder(); encoding = encoder.encodeToString((userID + ":" + pass).getBytes(StandardCharsets.UTF_8)); } |