diff options
Diffstat (limited to 'core/core-infrastructure/src/test')
9 files changed, 0 insertions, 661 deletions
diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/java/classes/ClassUtilsTest.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/java/classes/ClassUtilsTest.java deleted file mode 100644 index 060dccef3..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/java/classes/ClassUtilsTest.java +++ /dev/null @@ -1,70 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (c) 2020 Nordix Foundation. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.java.classes; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNull; - -import java.io.File; -import java.io.IOException; -import java.io.InputStream; -import java.util.Set; -import java.util.TreeSet; -import org.junit.Test; -import org.mockito.Mockito; - -public class ClassUtilsTest { - - @Test - public void testGetClassNames() throws IOException { - InputStream input = null; - ClassUtils.getClassNames(); - assertEquals(new TreeSet<>(), ClassUtils.processJar(input)); - } - - @Test - public void testProcessFileName() { - assertEquals("testing.txt", ClassUtils.processFileName("testing.txt")); - assertNull(ClassUtils.processFileName(null)); - assertEquals("", ClassUtils.processFileName("/classes/")); - } - - @Test - public void testProcessDir() throws Exception { - File mockFile = Mockito.mock(File.class); - Mockito.when(mockFile.isDirectory()).thenReturn(false); - assertEquals(new TreeSet<>(), ClassUtils.processDir(mockFile, "Here")); - assertEquals(new TreeSet<>(), ClassUtils.processDir(null, "Test")); - Mockito.when(mockFile.isDirectory()).thenReturn(true); - - File mockChildFile = Mockito.mock(File.class); - File[] files = {mockChildFile}; - Mockito.when(mockFile.listFiles()).thenReturn(files); - Mockito.when(mockChildFile.getName()).thenReturn("test.class"); - Mockito.when(mockChildFile.getAbsolutePath()).thenReturn("/test/"); - assertEquals(Set.of(".test."), ClassUtils.processDir(mockFile, "Here")); - Mockito.when(mockChildFile.getName()).thenReturn("test.class"); - assertEquals(Set.of(".test."), ClassUtils.processDir(mockFile, "Here")); - Mockito.when(mockChildFile.getName()).thenReturn("$test.class"); - assertEquals(new TreeSet<>(), ClassUtils.processDir(mockFile, "Here")); - } - -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/DummyMessageListener.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/DummyMessageListener.java deleted file mode 100644 index f81394c1c..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/DummyMessageListener.java +++ /dev/null @@ -1,62 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (C) 2016-2018 Ericsson. All rights reserved. - * Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.messaging; - -import com.google.common.eventbus.Subscribe; -import org.onap.policy.apex.core.infrastructure.messaging.impl.ws.messageblock.MessageBlock; -import org.slf4j.ext.XLogger; -import org.slf4j.ext.XLoggerFactory; - -/** - * The listener interface for receiving testMessage events. The class that is interested in processing a testMessage - * event implements this interface, and the object created with that class is registered with a component using the - * component's <code>addTestMessageListener</code> method. When the testMessage event occurs, that object's appropriate - * method is invoked. - * - */ -public abstract class DummyMessageListener implements MessageListener<String> { - - /** The Constant logger. */ - private static final XLogger logger = XLoggerFactory.getXLogger(DummyMessageListener.class); - - /** - * On command. - * - * @param data the data - */ - public abstract void onCommand(MessageBlock<String> data); - - /** - * {@inheritDoc}. - */ - @Subscribe - @Override - public final void onMessage(final MessageBlock<String> data) { - if (data != null) { - if (logger.isDebugEnabled()) { - logger.debug("{} command recieved from machine {} ", data.getMessages().size(), - data.getWebSocket().getRemoteSocketAddress().getHostString()); - } - onCommand(data); - } - } -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/EndToEndStringMessagingTest.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/EndToEndStringMessagingTest.java deleted file mode 100644 index e5375b770..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/EndToEndStringMessagingTest.java +++ /dev/null @@ -1,97 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (C) 2016-2018 Ericsson. All rights reserved. - * Modifications Copyright (C) 2020 Nordix Foundation. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.messaging; - -import static org.awaitility.Awaitility.await; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; - -import java.util.concurrent.TimeUnit; -import org.junit.Test; -import org.onap.policy.apex.core.infrastructure.messaging.stringmessaging.WsStringMessageClient; -import org.onap.policy.apex.core.infrastructure.messaging.stringmessaging.WsStringMessageListener; -import org.onap.policy.apex.core.infrastructure.messaging.stringmessaging.WsStringMessageServer; -import org.slf4j.ext.XLogger; -import org.slf4j.ext.XLoggerFactory; - -/** - * The Class EndToEndMessagingTest. - * - * @author Liam Fallon (liam.fallon@ericsson.com) - */ -public class EndToEndStringMessagingTest { - // Logger for this class - private static final XLogger logger = XLoggerFactory.getXLogger(EndToEndStringMessagingTest.class); - - private WsStringMessageServer server; - private WsStringMessageClient client; - - private boolean finished = false; - - @Test - public void testEndToEndMessaging() throws MessagingException { - logger.debug("end to end messaging test starting . . ."); - server = new WsStringMessageServer(44441); - assertNotNull(server); - server.start(new WsStringServerMessageListener()); - - await().atMost(2, TimeUnit.SECONDS).until(() -> server.isStarted()); - - try { - client = new WsStringMessageClient("localhost", 44441); - assertNotNull(client); - client.start(new WsStringClientMessageListener()); - - client.sendString("Hello, client here"); - - await().atLeast(50, TimeUnit.MILLISECONDS).until(() -> finished); - - } finally { - if (client != null) { - client.stop(); - } - if (server != null) { - server.stop(); - } - - } - logger.debug("end to end messaging test finished"); - } - - private class WsStringServerMessageListener implements WsStringMessageListener { - @Override - public void receiveString(final String stringMessage) { - logger.debug(stringMessage); - assertEquals("Hello, client here", stringMessage); - server.sendString("Hello back from server"); - } - } - - private class WsStringClientMessageListener implements WsStringMessageListener { - @Override - public void receiveString(final String stringMessage) { - logger.debug(stringMessage); - assertEquals("Hello back from server", stringMessage); - finished = true; - } - } -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/MessagingUtilsTest.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/MessagingUtilsTest.java deleted file mode 100644 index 6d5915ce8..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/MessagingUtilsTest.java +++ /dev/null @@ -1,71 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (c) 2020 Nordix Foundation. - * Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.messaging; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; -import java.net.InetAddress; -import java.net.UnknownHostException; -import org.junit.Test; -import org.onap.policy.apex.core.infrastructure.messaging.util.MessagingUtils; - -public class MessagingUtilsTest { - - @Test - public void testCheckPort() throws UnknownHostException, IOException { - assertEquals(1, MessagingUtils.checkPort(1)); - assertEquals(1, MessagingUtils.findPort(1)); - } - - @Test(expected = IllegalArgumentException.class) - public void testIllegalArgumentException() { - MessagingUtils.findPort(65536); - } - - @Test - public void testGetHost() throws UnknownHostException { - InetAddress host = InetAddress.getLocalHost(); - assertEquals(host, MessagingUtils.getHost()); - } - - @Test - public void testValidAllocateAddress() throws UnknownHostException { - assertNotNull(MessagingUtils.getLocalHostLanAddress()); - int allocatedPort = MessagingUtils.allocateAddress(3306); - assertTrue(allocatedPort >= 3306 && allocatedPort < 65536); - } - - @Test(expected = IllegalArgumentException.class) - public void testInvalidAllocateAddress() { - MessagingUtils.allocateAddress(1); - } - - @Test - public void testSerializeObject() { - String testString = "Test"; - MessagingUtils.serializeObject(new Object()); - assertNotNull(MessagingUtils.serializeObject(testString)); - } -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/StringTestServer.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/StringTestServer.java deleted file mode 100644 index 9cf99feb3..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/messaging/StringTestServer.java +++ /dev/null @@ -1,111 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (C) 2016-2018 Ericsson. All rights reserved. - * Modifications Copyright (C) 2020 Nordix Foundation. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.messaging; - -import static org.junit.Assert.assertNotNull; - -import org.onap.policy.apex.core.infrastructure.messaging.stringmessaging.WsStringMessageListener; -import org.onap.policy.apex.core.infrastructure.messaging.stringmessaging.WsStringMessageServer; -import org.onap.policy.apex.core.infrastructure.threading.ThreadUtilities; - -/** - * The Class StringTestServer. - */ -public class StringTestServer { - private WsStringMessageServer server; - - /** - * Create a string test server. - * - * @param port port to use - * @param timeToLive time to live - * @throws MessagingException exceptions on messages - */ - public StringTestServer(final int port, long timeToLive) throws MessagingException { - System.out.println("StringTestServer starting on port " + port + " for " + timeToLive + " seconds . . ."); - server = new WsStringMessageServer(port); - assertNotNull(server); - server.start(new WsStringServerMessageListener()); - - System.out.println("StringTestServer started on port " + port + " for " + timeToLive + " seconds"); - - // convert to milliSeconds - ThreadUtilities.sleep(1000 * timeToLive); - - server.stop(); - System.out.println("StringTestServer completed"); - } - - /** - * The listener interface for receiving WSStringServerMessage events. The class that is interested in processing a - * WSStringServerMessage event implements this interface, and the object created with that class is registered with - * a component using the component's <code>addWSStringServerMessageListener</code> method. When the - * WSStringServerMessage event occurs, that object's appropriate method is invoked. - * - * @see WSStringServerMessageEvent - */ - private class WsStringServerMessageListener implements WsStringMessageListener { - - /** - * {@inheritDoc}. - */ - @Override - public void receiveString(final String stringMessage) { - System.out.println("Server received string \"" + stringMessage + "\""); - server.sendString("Server echoing back the message: \"" + stringMessage + "\""); - } - } - - /** - * The main method. - * - * @param args the arguments - * @throws MessagingException the messaging exception - */ - public static void main(final String[] args) throws MessagingException { - if (args.length != 2) { - System.err.println("Usage: StringTestServer port timeToLive"); - return; - } - - int port = 0; - try { - port = Integer.parseInt(args[0]); - } catch (final Exception e) { - System.err.println("Usage: StringTestServer port timeToLive"); - e.printStackTrace(); - return; - } - - long timeToLive = 0; - try { - timeToLive = Long.parseLong(args[1]); - } catch (final Exception e) { - System.err.println("Usage: StringTestServer port timeToLive"); - e.printStackTrace(); - return; - } - - new StringTestServer(port, timeToLive); - - } -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/threading/ThreadingTest.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/threading/ThreadingTest.java deleted file mode 100644 index 35ad9386a..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/threading/ThreadingTest.java +++ /dev/null @@ -1,86 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * Copyright (C) 2016-2018 Ericsson. All rights reserved. - * Modifications Copyright (C) 2020 Nordix Foundation. - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.threading; - -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; - -import java.util.ArrayList; -import java.util.List; -import org.junit.Test; -import org.slf4j.ext.XLogger; -import org.slf4j.ext.XLoggerFactory; - -/** - * The Class ThreadingTest. - * - * @author Liam Fallon (liam.fallon@ericsson.com) - */ -public class ThreadingTest { - - private static final String LOCAL_NAME = "localName"; - // Logger for this class - private static final XLogger logger = XLoggerFactory.getXLogger(ThreadingTest.class); - - /** - * Test thread factory initialization. - */ - @Test - public void testThreadFactoryInitialization() { - final ApplicationThreadFactory objUnderTest = new ApplicationThreadFactory(LOCAL_NAME, 0); - assertNotNull("Failed to create ApplicationThreadFactory threadFactory0", objUnderTest); - logger.debug(objUnderTest.toString()); - assertTrue("Failed to name ApplicationThreadFactory threadFactory0", - objUnderTest.getName().startsWith("Apex-" + LOCAL_NAME)); - - final ApplicationThreadFactory objUnderTest1 = new ApplicationThreadFactory(LOCAL_NAME, 0); - assertNotNull("Failed to create ApplicationThreadFactory threadFactory1", objUnderTest1); - logger.debug(objUnderTest1.toString()); - assertTrue("Failed to name ApplicationThreadFactory threadFactory1", - objUnderTest1.getName().startsWith("Apex-" + LOCAL_NAME)); - - testThreadFactory(objUnderTest); - testThreadFactory(objUnderTest1); - } - - /** - * Test thread factory. - * - * @param threadFactory the thread factory - */ - private void testThreadFactory(final ApplicationThreadFactory threadFactory) { - final List<Thread> threadList = new ArrayList<>(); - - for (int i = 0; i < 5; i++) { - final Thread thread = threadFactory.newThread(() -> { - }); - threadList.add(thread); - thread.start(); - } - - for (int i = 0; i < 5; i++) { - Thread thread = threadList.get(i); - assertTrue(thread.getName().startsWith("Apex-" + LOCAL_NAME)); - assertTrue(thread.getName().contains(":" + i)); - } - } -} diff --git a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/xml/XPathReaderTest.java b/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/xml/XPathReaderTest.java deleted file mode 100644 index a3395ae1f..000000000 --- a/core/core-infrastructure/src/test/java/org/onap/policy/apex/core/infrastructure/xml/XPathReaderTest.java +++ /dev/null @@ -1,74 +0,0 @@ -/* - * ============LICENSE_START======================================================= - * Copyright (C) 2020 Nordix Foundation - * ================================================================================ - * 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. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -package org.onap.policy.apex.core.infrastructure.xml; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertNull; - -import java.io.IOException; -import java.net.URL; -import javax.xml.xpath.XPathConstants; -import org.junit.Test; - -public class XPathReaderTest { - - final URL testResource = getClass().getClassLoader().getResource("xmlTestFile.xml"); - - @Test - public void canConstructWithFromFile() { - final XPathReader objectUnderTest = new XPathReader(testResource.getFile()); - assertNotNull(objectUnderTest); - } - - @Test - public void canConstructWithStream() throws IOException { - final XPathReader objectUnderTest = new XPathReader(testResource.openStream()); - assertNotNull(objectUnderTest); - } - - @Test - public void canConstructWithNull() { - final XPathReader objectUnderTest = new XPathReader((String) null); - assertNotNull(objectUnderTest); - } - - @Test - public void canConstructWithInvalidFileName() { - final XPathReader objectUnderTest = new XPathReader(""); - assertNotNull(objectUnderTest); - } - - @Test - public void readReturnsCorrectValueWhenUsingCorrectXpath() throws IOException { - final XPathReader objectUnderTest = new XPathReader(testResource.openStream()); - final String validXPathExpression = "/example/name"; - final Object result = objectUnderTest.read(validXPathExpression, XPathConstants.STRING); - assertEquals("This is my name", result); - } - - @Test - public void readReturnsNullWhenUsingInvalidXpath() throws IOException { - final XPathReader objectUnderTest = new XPathReader(testResource.openStream()); - final String invalidXPathExpression = ""; - assertNull(objectUnderTest.read(invalidXPathExpression, XPathConstants.STRING)); - } - -} diff --git a/core/core-infrastructure/src/test/resources/logback-test.xml b/core/core-infrastructure/src/test/resources/logback-test.xml deleted file mode 100644 index c52f2ded6..000000000 --- a/core/core-infrastructure/src/test/resources/logback-test.xml +++ /dev/null @@ -1,70 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - ============LICENSE_START======================================================= - Copyright (C) 2016-2018 Ericsson. All rights reserved. - ================================================================================ - 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. - See the License for the specific language governing permissions and - limitations under the License. - - SPDX-License-Identifier: Apache-2.0 - ============LICENSE_END========================================================= ---> - -<configuration> - - <contextName>Apex</contextName> - <statusListener class="ch.qos.logback.core.status.OnConsoleStatusListener" /> - <property name="LOG_DIR" value="${java.io.tmpdir}/apex_logging/" /> - - <!-- USE FOR STD OUT ONLY --> - <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> - <encoder> - <Pattern>%d %contextName [%t] %level %logger{36} - %msg%n</Pattern> - </encoder> - </appender> - - <root level="INFO"> - <appender-ref ref="STDOUT" /> - </root> - - <logger name="org.infinispan" level="INFO" additivity="false"> - <appender-ref ref="STDOUT" /> - </logger> - - <logger name="org.apache.zookeeper.ClientCnxn" level="OFF" additivity="false"> - <appender-ref ref="STDOUT" /> - </logger> - - <appender name="FILE" class="ch.qos.logback.core.FileAppender"> - <file>${LOG_DIR}/apex.log</file> - <encoder> - <pattern>%d %-5relative [procId=${processId}] [%thread] %-5level - %logger{26} - %msg %n %ex{full}</pattern> - </encoder> - </appender> - - <appender name="CTXT_FILE" class="ch.qos.logback.core.FileAppender"> - <file>${LOG_DIR}/apex_ctxt.log</file> - <encoder> - <pattern>%d %-5relative [procId=${processId}] [%thread] %-5level - %logger{26} - %msg %n %ex{full}</pattern> - </encoder> - </appender> - - <logger name="org.onap.policy.apex.core.context.impl.monitoring" level="INFO" additivity="false"> - <appender-ref ref="CTXT_FILE" /> - </logger> - - <logger name="org.onap.policy.apex.core.context" level="INFO" additivity="false"> - <appender-ref ref="STDOUT" /> - </logger> -</configuration> diff --git a/core/core-infrastructure/src/test/resources/xmlTestFile.xml b/core/core-infrastructure/src/test/resources/xmlTestFile.xml deleted file mode 100644 index 73359a1d6..000000000 --- a/core/core-infrastructure/src/test/resources/xmlTestFile.xml +++ /dev/null @@ -1,20 +0,0 @@ -<?xml version='1.0'?> -<!-- - ============LICENSE_START======================================================= - Copyright (C) 2020 Nordix Foundation. - ================================================================================ - 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. - See the License for the specific language governing permissions and - limitations under the License. - SPDX-License-Identifier: Apache-2.0 - ============LICENSE_END========================================================= ---> -<example> - <name>This is my name</name> -</example> |