Author: carnold
Date: Wed Dec 21 10:30:44 2005
New Revision: 358337
URL: http://svn.apache.org/viewcvs?rev=358337&view=rev
Log:
Bug 35452: Tests for constants missing in 1.3 branch
Added:
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/LogManagerTest.java
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/helpers/LogLogTest.java
Modified:
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/CoreTestSuite.java
Modified:
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/CoreTestSuite.java
URL:
http://svn.apache.org/viewcvs/logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/CoreTestSuite.java?rev=358337&r1=358336&r2=358337&view=diff
==============================================================================
---
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/CoreTestSuite.java
(original)
+++
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/CoreTestSuite.java
Wed Dec 21 10:30:44 2005
@@ -24,7 +24,6 @@
* Suite of log4j class level unit tests.
*
* @author Curt Arnold
- * @since 1.3
*/
public class CoreTestSuite {
/**
@@ -36,6 +35,8 @@
s.addTestSuite(LoggingEventTest.class);
s.addTestSuite(org.apache.log4j.LevelTest.class);
s.addTestSuite(org.apache.log4j.FileAppenderTest.class);
+ s.addTestSuite(org.apache.log4j.LogManagerTest.class);
+ s.addTestSuite(org.apache.log4j.helpers.LogLogTest.class);
return s;
}
}
Added:
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/LogManagerTest.java
URL:
http://svn.apache.org/viewcvs/logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/LogManagerTest.java?rev=358337&view=auto
==============================================================================
---
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/LogManagerTest.java
(added)
+++
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/LogManagerTest.java
Wed Dec 21 10:30:44 2005
@@ -0,0 +1,74 @@
+/*
+ * Copyright 1999,2005 The Apache Software 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.
+ */
+
+package org.apache.log4j;
+
+import junit.framework.TestCase;
+
+
+/**
+ * Tests for LogManager
+ *
+ * @author Curt Arnold
+ **/
+public class LogManagerTest extends TestCase {
+ /**
+ * Create new instance of LogManagerTest.
+ * @param testName test name
+ */
+ public LogManagerTest(final String testName) {
+ super(testName);
+ }
+
+ /**
+ * Check value of DEFAULT_CONFIGURATION_FILE.
+ * @deprecated since constant is deprecated
+ */
+ public void testDefaultConfigurationFile() {
+ assertEquals("log4j.properties", LogManager.DEFAULT_CONFIGURATION_FILE);
+ }
+
+ /**
+ * Check value of DEFAULT_XML_CONFIGURATION_FILE.
+ */
+ public void testDefaultXmlConfigurationFile() {
+ assertEquals("log4j.xml", LogManager.DEFAULT_XML_CONFIGURATION_FILE);
+ }
+
+ /**
+ * Check value of DEFAULT_CONFIGURATION_KEY.
+ * @deprecated since constant is deprecated
+ */
+ public void testDefaultConfigurationKey() {
+ assertEquals("log4j.configuration", LogManager.DEFAULT_CONFIGURATION_KEY);
+ }
+
+ /**
+ * Check value of CONFIGURATOR_CLASS_KEY.
+ * @deprecated since constant is deprecated
+ */
+ public void testConfiguratorClassKey() {
+ assertEquals("log4j.configuratorClass",
LogManager.CONFIGURATOR_CLASS_KEY);
+ }
+
+ /**
+ * Check value of DEFAULT_INIT_OVERRIDE_KEY.
+ * @deprecated since constant is deprecated
+ */
+ public void testDefaultInitOverrideKey() {
+ assertEquals("log4j.defaultInitOverride",
LogManager.DEFAULT_INIT_OVERRIDE_KEY);
+ }
+}
Added:
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/helpers/LogLogTest.java
URL:
http://svn.apache.org/viewcvs/logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/helpers/LogLogTest.java?rev=358337&view=auto
==============================================================================
---
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/helpers/LogLogTest.java
(added)
+++
logging/log4j/branches/v1_2-branch/tests/src/java/org/apache/log4j/helpers/LogLogTest.java
Wed Dec 21 10:30:44 2005
@@ -0,0 +1,50 @@
+/*
+ * Copyright 1999,2005 The Apache Software 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.
+ */
+
+package org.apache.log4j.helpers;
+
+import junit.framework.TestCase;
+
+
+/**
+ * Tests for LogLog.
+ *
+ * @author Curt Arnold
+ **/
+public class LogLogTest extends TestCase {
+ /**
+ * Create new instance of LogLogTest.
+ * @param testName test name
+ */
+ public LogLogTest(final String testName) {
+ super(testName);
+ }
+
+ /**
+ * Check value of DEBUG_KEY.
+ */
+ public void testDebugKey() {
+ assertEquals("log4j.debug", LogLog.DEBUG_KEY);
+ }
+
+ /**
+ * Check value of CONFIG_DEBUG_KEY.
+ * @deprecated since constant is deprecated
+ */
+ public void testConfigDebugKey() {
+ assertEquals("log4j.configDebug", LogLog.CONFIG_DEBUG_KEY);
+ }
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]