logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kamal Ahmed <KAh...@webMethods.com>
Subject testdecide() error
Date Wed, 01 Feb 2006 23:12:06 GMT
Hi,
Why do you think, I am getting an error, when I run the test case

I use the following test case, I get error: I would appreciate any help.
 
Test Case:
 
public void testdecide() { 
                   Logger logger = Logger
 
.getLogger("com.webmethods.sc.logging.test.unit.WmLoggerFilterTes");
                   WmLoggerFilter subjectWmLoggerFilter = new
WmLoggerFilter();
                   MessageRenderer mr = new MessageRenderer();
                   Throwable e = new Throwable("exception");
                   assertEquals(Filter.DENY,
subjectWmLoggerFilter.decide(null));
                   assertEquals(
                                      Filter.NEUTRAL,
                                      subjectWmLoggerFilter
 
.decide(createEvent("com.webmethods.sc.logging.test.unit.WmLoggerFilterTes")
));
                   System.out.println(Filter.DENY);
                   System.out.println(subjectWmLoggerFilter.decide(null));
                   System.out.println(Filter.NEUTRAL);
                   assertEquals(Filter.NEUTRAL, 0);
                   LoggingEvent le = new LoggingEvent(
 
"com.webmethods.sc.logging.test.unit.WmLoggerFilterTest",
                                      logger, Level.DEBUG, mr, e);
                   assertEquals(Filter.NEUTRAL,
subjectWmLoggerFilter.decide(le));
                   System.out.println(subjectWmLoggerFilter.decide(le));
          }

Error trace:
 
java.lang.NoClassDefFoundError: javax/jms/JMSException

          at
com.webmethods.sc.logging.test.unit.WmLoggerFilterTest.testdecide(WmLoggerFi
lterTest.java:125)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)
          at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)
          at java.lang.reflect.Method.invoke(Method.java:585)
          at junit.framework.TestCase.runTest(TestCase.java:154)
          at junit.framework.TestCase.runBare(TestCase.java:127)
          at junit.framework.TestResult$1.protect(TestResult.java:106)
          at junit.framework.TestResult.runProtected(TestResult.java:124)
          at junit.framework.TestResult.run(TestResult.java:109)
          at junit.framework.TestCase.run(TestCase.java:118)
          at junit.framework.TestSuite.runTest(TestSuite.java:208)
          at junit.framework.TestSuite.run(TestSuite.java:203)
          at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRu
nner.java:999)
          at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.
java:423)
          at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.
java:598)
          at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner
.java:235) 

Thanks,

-Kamal.

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message