[jboss-cvs] JBossAS SVN: r94612 - projects/jboss-osgi/trunk/testsuite/functional/src/test/java/org/jboss/test/osgi/jbosgi161/bundle.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Fri Oct 9 12:30:52 EDT 2009
Author: thomas.diesler at jboss.com
Date: 2009-10-09 12:30:52 -0400 (Fri, 09 Oct 2009)
New Revision: 94612
Modified:
projects/jboss-osgi/trunk/testsuite/functional/src/test/java/org/jboss/test/osgi/jbosgi161/bundle/OSGI161Activator.java
Log:
Allow org.apache.commons.logging.impl.Log4JLogger
Modified: projects/jboss-osgi/trunk/testsuite/functional/src/test/java/org/jboss/test/osgi/jbosgi161/bundle/OSGI161Activator.java
===================================================================
--- projects/jboss-osgi/trunk/testsuite/functional/src/test/java/org/jboss/test/osgi/jbosgi161/bundle/OSGI161Activator.java 2009-10-09 16:13:02 UTC (rev 94611)
+++ projects/jboss-osgi/trunk/testsuite/functional/src/test/java/org/jboss/test/osgi/jbosgi161/bundle/OSGI161Activator.java 2009-10-09 16:30:52 UTC (rev 94612)
@@ -23,6 +23,9 @@
// $Id:$
+import java.util.ArrayList;
+import java.util.List;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.osgi.framework.BundleActivator;
@@ -48,7 +51,12 @@
Log log = LogFactory.getLog(OSGI161Activator.class);
String loggerClass = log.getClass().getName();
- if ("org.apache.commons.logging.impl.SLF4JLocationAwareLog".equals(loggerClass) == false)
+
+ List<String> expected = new ArrayList<String>();
+ expected.add("org.apache.commons.logging.impl.Log4JLogger");
+ expected.add("org.apache.commons.logging.impl.SLF4JLocationAwareLog");
+
+ if (expected.contains(loggerClass) == false)
throw new IllegalStateException("Unexpected logger: " + loggerClass);
log.info("*******************************************");
@@ -61,7 +69,11 @@
Logger log = LoggerFactory.getLogger(OSGI161Activator.class);
String loggerClass = log.getClass().getName();
- if ("org.slf4j.impl.Log4jLoggerAdapter".equals(loggerClass) == false)
+
+ List<String> expected = new ArrayList<String>();
+ expected.add("org.slf4j.impl.Log4jLoggerAdapter");
+
+ if (expected.contains(loggerClass) == false)
throw new IllegalStateException("Unexpected logger: " + loggerClass);
log.info("*******************************************");
More information about the jboss-cvs-commits
mailing list