ceki 2002/08/28 14:19:48
Modified: tests Tag: v1_2-branch build.xml
Added: tests/input Tag: v1_2-branch defaultInit3.properties
tests/input/xml Tag: v1_2-branch defaultInit.xml
tests/src/java/org/apache/log4j/defaultInit Tag: v1_2-branch
TestCase1.java TestCase2.java TestCase3.java
TestCase4.java
Log:
Added test cases for default initialization procedure. We now search
for the file log4j.xml as well as the file log4j.properties in log4j
initialization.
Revision Changes Path
No revision
No revision
1.16.2.5 +51 -1 jakarta-log4j/tests/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-log4j/tests/build.xml,v
retrieving revision 1.16.2.4
retrieving revision 1.16.2.5
diff -u -r1.16.2.4 -r1.16.2.5
--- build.xml 26 Jul 2002 18:23:34 -0000 1.16.2.4
+++ build.xml 28 Aug 2002 21:19:48 -0000 1.16.2.5
@@ -96,7 +96,7 @@
<!-- ================================================================= -->
<target name="regression" depends="Minimum, Logger, DOM, CustomLevel,
CustomLogger, PatternLayout,
- HierarchyThreshold, SocketServer,
+ HierarchyThreshold, DefaultInit, SocketServer,
XMLLayout, AsyncAppender,
OptionConverter, BoundedFIFO,
CyclicBuffer, PatternParser, OR,
@@ -165,6 +165,56 @@
<formatter type="plain" usefile="false" />
<test name="org.apache.log4j.customLogger.XLoggerTestCase" />
</junit>
+ </target>
+
+ <target name="DefaultInit" depends="build">
+ <!-- Delete possible cruft from previous runs. -->
+ <delete file="classes/log4j.xml"/>
+ <delete file="classes/log4j.properties"/>
+
+ <junit printsummary="yes" fork="yes" haltonfailure="yes">
+ <classpath refid="tests.classpath"/>
+ <formatter type="plain" usefile="false"/>
+ <test fork="true" name="org.apache.log4j.defaultInit.TestCase1" />
+ </junit>
+
+ <copy file="input/xml/defaultInit.xml" tofile="classes/log4j.xml"/>
+ <junit printsummary="yes" fork="yes" haltonfailure="yes">
+ <classpath refid="tests.classpath"/>
+ <formatter type="plain" usefile="false"/>
+ <test fork="true" name="org.apache.log4j.defaultInit.TestCase2" />
+ </junit>
+ <delete file="classes/log4j.xml"/>
+
+ <!-- test handling of log4j.defaultInitOverride system property -->
+ <copy file="input/xml/defaultInit.xml" tofile="classes/log4j.xml"/>
+ <junit printsummary="yes" fork="yes" haltonfailure="yes">
+ <jvmarg value="-Dlog4j.defaultInitOverride=true"/>
+ <classpath refid="tests.classpath"/>
+ <formatter type="plain" usefile="false"/>
+ <test fork="true" name="org.apache.log4j.defaultInit.TestCase1" />
+ </junit>
+ <delete file="classes/log4j.xml"/>
+
+ <!-- test default initialization from log4j.xml -->
+ <copy file="input/defaultInit3.properties" tofile="classes/log4j.properties"/>
+ <junit printsummary="yes" fork="yes" haltonfailure="yes">
+ <classpath refid="tests.classpath"/>
+ <formatter type="plain" usefile="false"/>
+ <test fork="true" name="org.apache.log4j.defaultInit.TestCase3" />
+ </junit>
+ <delete file="classes/log4j.properties"/>
+
+ <!-- test default initialization from log4j.properties -->
+ <copy file="input/xml/defaultInit.xml" tofile="classes/log4j.xml"/>
+ <copy file="input/defaultInit3.properties" tofile="classes/log4j.properties"/>
+ <junit printsummary="yes" fork="yes" haltonfailure="yes">
+ <classpath refid="tests.classpath"/>
+ <formatter type="plain" usefile="false"/>
+ <test fork="true" name="org.apache.log4j.defaultInit.TestCase4" />
+ </junit>
+ <delete file="classes/log4j.xml"/>
+ <delete file="classes/log4j.properties"/>
</target>
<target name="SocketServer" depends="build">
No revision
No revision
1.1.2.1 +7 -0 jakarta-log4j/tests/input/Attic/defaultInit3.properties
No revision
No revision
1.1.2.1 +17 -0 jakarta-log4j/tests/input/xml/Attic/defaultInit.xml
No revision
No revision
1.1.2.1 +45 -0
jakarta-log4j/tests/src/java/org/apache/log4j/defaultInit/Attic/TestCase1.java
1.1.2.1 +49 -0
jakarta-log4j/tests/src/java/org/apache/log4j/defaultInit/Attic/TestCase2.java
1.1.2.1 +49 -0
jakarta-log4j/tests/src/java/org/apache/log4j/defaultInit/Attic/TestCase3.java
1.1.2.1 +50 -0
jakarta-log4j/tests/src/java/org/apache/log4j/defaultInit/Attic/TestCase4.java
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>