X-Git-Url: https://gerrit.onap.org/r/gitweb?p=policy%2Fengine.git;a=blobdiff_plain;f=ONAP-PAP-REST%2Fsrc%2Ftest%2Fjava%2Forg%2Fonap%2Fpolicy%2Fpap%2Fxacml%2Frest%2Fhandler%2FDictionaryHandlerTest.java;h=8c35c17ef2777116a4191bcd9ad80915b0ae60b3;hp=6b58184fe53ccf90db5fa4bbeb7cac5ff23d967a;hb=1e61676b77dd09659027b8984f050df7e8538526;hpb=ef59cda51b8320446dc235288340b711367c6c2e diff --git a/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/handler/DictionaryHandlerTest.java b/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/handler/DictionaryHandlerTest.java index 6b58184fe..8c35c17ef 100644 --- a/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/handler/DictionaryHandlerTest.java +++ b/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/handler/DictionaryHandlerTest.java @@ -2,14 +2,16 @@ * ============LICENSE_START======================================================= * ONAP-PAP-REST * ================================================================================ - * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved. + * Copyright (C) 2018-2019 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Modifications Copyright (C) 2019 Samsung * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -21,24 +23,25 @@ package org.onap.policy.pap.xacml.rest.handler; import static org.junit.Assert.assertNull; + import org.junit.Test; public class DictionaryHandlerTest { - @Test - public void negTestHandler() { - // Set the system property temporarily - String systemKey = "dictionary.impl.className"; - String oldProperty = System.getProperty(systemKey); - System.setProperty(systemKey, "foobar"); + @Test + public void negTestHandler() { + // Set the system property temporarily + String systemKey = "dictionary.impl.className"; + String oldProperty = System.getProperty(systemKey); + System.setProperty(systemKey, "foobar"); - // Run negative test on instance - assertNull(DictionaryHandler.getInstance()); + // Run negative test on instance + assertNull(DictionaryHandler.getInstance()); - // Restore the original system property - if (oldProperty != null) { - System.setProperty(systemKey, oldProperty); - } else { - System.clearProperty(systemKey); + // Restore the original system property + if (oldProperty != null) { + System.setProperty(systemKey, oldProperty); + } else { + System.clearProperty(systemKey); + } } - } }