[jboss-as7-dev] EJB - org.jboss.as.ejb3.pool.strictmax.StrictMaxUnitTestCase accidentally failed (race-condition?)

Pavel Janousek Pavel.Janousek at redhat.com
Mon Mar 5 08:17:21 EST 2012


Hi,

I've got for the first time (and only one) that testcase org.jboss.as.ejb3.pool.strictmax.StrictMaxUnitTestCase accidentally failed - see stacktrace bellow.

Because it is some multithread testcase, it is possible that this accident should be a race-condition error.

Could someone who is expert of this part of AS7 code review if there isn't really some issue?

Thanks

Pavel

-------------------------------------------------------------------------------                                                                                                                                                              
Test set: org.jboss.as.ejb3.pool.strictmax.StrictMaxUnitTestCase                                                                                                                                                                             
-------------------------------------------------------------------------------                                                                                                                                                              
Tests run: 3, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3.067 sec <<< FAILURE!                                                                                                                                                       
testMultiThread(org.jboss.as.ejb3.pool.strictmax.StrictMaxUnitTestCase)  Time elapsed: 2.031 sec  <<< FAILURE!                                                                                                                               
junit.framework.AssertionFailedError: expected:<10> but was:<9>                                                                                                                                                                              
        at junit.framework.Assert.fail(Assert.java:50)                                                                                                                                                                                       
        at junit.framework.Assert.failNotEquals(Assert.java:287)                                                                                                                                                                             
        at junit.framework.Assert.assertEquals(Assert.java:67)                                                                                                                                                                               
        at junit.framework.Assert.assertEquals(Assert.java:199)                                                                                                                                                                              
        at junit.framework.Assert.assertEquals(Assert.java:205)                                                                                                                                                                              
        at org.jboss.as.ejb3.pool.strictmax.StrictMaxUnitTestCase.testMultiThread(StrictMaxUnitTestCase.java:117)                                                                                                                            
        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:597)                                                                                                                                                                                  
        at junit.framework.TestCase.runTest(TestCase.java:168)                                                                                                                                                                               
        at junit.framework.TestCase.runBare(TestCase.java:134)                                                                                                                                                                               
        at junit.framework.TestResult$1.protect(TestResult.java:110)                                                                                                                                                                         
        at junit.framework.TestResult.runProtected(TestResult.java:128)                                                                                                                                                                      
        at junit.framework.TestResult.run(TestResult.java:113)                                                                                                                                                                               
        at junit.framework.TestCase.run(TestCase.java:124)                                                                                                                                                                                   
        at junit.framework.TestSuite.runTest(TestSuite.java:243)                                                                                                                                                                             
        at junit.framework.TestSuite.run(TestSuite.java:238)                                                                                                                                                                                 
        at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)                                                                                                                                                     
        at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:53)                                                                                                                                                     
        at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:123)                                                                                                                                           
        at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:104)                                                                                                                                                   
        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:597)                                                                                                                                                                                  
        at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:164)                                                                                                                                    
        at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:110)                                                                                                                                   
        at org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:175)                                                                                                                                         
        at org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcessWhenForked(SurefireStarter.java:107)                                                                                                                           
        at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:68)                                                                                                                                                          
 

--
Pavel Janousek
Senior JBoss QA Engineer




More information about the jboss-as7-dev mailing list