You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by ma...@apache.org on 2014/09/30 04:33:50 UTC

[6/6] git commit: Move test log4j config files.

Move test log4j config files.


Project: http://git-wip-us.apache.org/repos/asf/logging-log4j2/repo
Commit: http://git-wip-us.apache.org/repos/asf/logging-log4j2/commit/431df291
Tree: http://git-wip-us.apache.org/repos/asf/logging-log4j2/tree/431df291
Diff: http://git-wip-us.apache.org/repos/asf/logging-log4j2/diff/431df291

Branch: refs/heads/master
Commit: 431df291362476fc103d4735fcfa1a65e9c964c4
Parents: 20c80a9
Author: Matt Sicker <ma...@apache.org>
Authored: Mon Sep 29 21:33:38 2014 -0500
Committer: Matt Sicker <ma...@apache.org>
Committed: Mon Sep 29 21:33:38 2014 -0500

----------------------------------------------------------------------
 .../logging/log4j/web/ServletAppenderTest.java  |  2 +-
 .../apache/logging/log4j/web/WebLookupTest.java |  2 +-
 .../resources/WEB-INF/classes/log4j-servlet.xml | 33 ++++++++++++++++++++
 .../resources/WEB-INF/classes/log4j-webvar.xml  | 29 +++++++++++++++++
 log4j-web/src/test/resources/log4j-servlet.xml  | 33 --------------------
 log4j-web/src/test/resources/log4j-webvar.xml   | 29 -----------------
 6 files changed, 64 insertions(+), 64 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/java/org/apache/logging/log4j/web/ServletAppenderTest.java
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/java/org/apache/logging/log4j/web/ServletAppenderTest.java b/log4j-web/src/test/java/org/apache/logging/log4j/web/ServletAppenderTest.java
index e9bcc3d..d69455f 100644
--- a/log4j-web/src/test/java/org/apache/logging/log4j/web/ServletAppenderTest.java
+++ b/log4j-web/src/test/java/org/apache/logging/log4j/web/ServletAppenderTest.java
@@ -34,7 +34,7 @@ import static org.junit.Assert.*;
  */
 public class ServletAppenderTest {
 
-    private static final String CONFIG = "log4j-servlet.xml";
+    private static final String CONFIG = "WEB-INF/classes/log4j-servlet.xml";
 
     @Test
     public void testAppender() throws Exception {

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/java/org/apache/logging/log4j/web/WebLookupTest.java
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/java/org/apache/logging/log4j/web/WebLookupTest.java b/log4j-web/src/test/java/org/apache/logging/log4j/web/WebLookupTest.java
index 6cf8a6b..a93262e 100644
--- a/log4j-web/src/test/java/org/apache/logging/log4j/web/WebLookupTest.java
+++ b/log4j-web/src/test/java/org/apache/logging/log4j/web/WebLookupTest.java
@@ -79,7 +79,7 @@ public class WebLookupTest {
         servletContext.setInitParameter("myapp.logdir", "target");
         servletContext.setAttribute("Name1", "Ben");
         servletContext.setInitParameter("Name2", "Jerry");
-        servletContext.setInitParameter("log4jConfiguration", "log4j-webvar.xml");
+        servletContext.setInitParameter("log4jConfiguration", "WEB-INF/classes/log4j-webvar.xml");
         final Log4jWebLifeCycle initializer = WebLoggerContextUtils.getWebLifeCycle(servletContext);
         initializer.start();
         initializer.setLoggerContext();

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/resources/WEB-INF/classes/log4j-servlet.xml
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/resources/WEB-INF/classes/log4j-servlet.xml b/log4j-web/src/test/resources/WEB-INF/classes/log4j-servlet.xml
new file mode 100644
index 0000000..c4ede54
--- /dev/null
+++ b/log4j-web/src/test/resources/WEB-INF/classes/log4j-servlet.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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.
+
+-->
+<Configuration status="OFF" name="ServletTest">
+
+    <Appenders>
+        <Servlet name="Servlet">
+            <PatternLayout pattern="%m%n"/>
+        </Servlet>
+    </Appenders>
+
+    <Loggers>
+        <Root level="debug">
+            <AppenderRef ref="Servlet"/>
+        </Root>
+    </Loggers>
+
+</Configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/resources/WEB-INF/classes/log4j-webvar.xml
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/resources/WEB-INF/classes/log4j-webvar.xml b/log4j-web/src/test/resources/WEB-INF/classes/log4j-webvar.xml
new file mode 100644
index 0000000..de3777a
--- /dev/null
+++ b/log4j-web/src/test/resources/WEB-INF/classes/log4j-webvar.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one or more
+  ~ contributor license agreements. See the NOTICE file distributed with
+  ~ this work for additional information regarding copyright ownership.
+  ~ The ASF licenses this file to You 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.
+  -->
+<Configuration status="OFF">
+  <Appenders>
+    <File name="file" fileName="${web:initParam.myapp.logdir}/myapp.log" append="true">
+      <PatternLayout pattern="%d [%t] %-5p %c - %m%n"/>
+    </File>
+  </Appenders>
+  <Loggers>
+    <Root level="warn">
+      <AppenderRef ref="file"/>
+    </Root>
+  </Loggers>
+</Configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/resources/log4j-servlet.xml
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/resources/log4j-servlet.xml b/log4j-web/src/test/resources/log4j-servlet.xml
deleted file mode 100644
index c4ede54..0000000
--- a/log4j-web/src/test/resources/log4j-servlet.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements.  See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You 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.
-
--->
-<Configuration status="OFF" name="ServletTest">
-
-    <Appenders>
-        <Servlet name="Servlet">
-            <PatternLayout pattern="%m%n"/>
-        </Servlet>
-    </Appenders>
-
-    <Loggers>
-        <Root level="debug">
-            <AppenderRef ref="Servlet"/>
-        </Root>
-    </Loggers>
-
-</Configuration>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/431df291/log4j-web/src/test/resources/log4j-webvar.xml
----------------------------------------------------------------------
diff --git a/log4j-web/src/test/resources/log4j-webvar.xml b/log4j-web/src/test/resources/log4j-webvar.xml
deleted file mode 100644
index de3777a..0000000
--- a/log4j-web/src/test/resources/log4j-webvar.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one or more
-  ~ contributor license agreements. See the NOTICE file distributed with
-  ~ this work for additional information regarding copyright ownership.
-  ~ The ASF licenses this file to You 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.
-  -->
-<Configuration status="OFF">
-  <Appenders>
-    <File name="file" fileName="${web:initParam.myapp.logdir}/myapp.log" append="true">
-      <PatternLayout pattern="%d [%t] %-5p %c - %m%n"/>
-    </File>
-  </Appenders>
-  <Loggers>
-    <Root level="warn">
-      <AppenderRef ref="file"/>
-    </Root>
-  </Loggers>
-</Configuration>
\ No newline at end of file