I get a failure on the one below when running in parallel, but not standalone:
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 10.358 sec <<< FAILURE! testRun(org.apache.mahout.text.SequenceFilesFromLuceneStorageMRJobTest) Time elapsed: 10.358 sec <<< FAILURE! java.lang.AssertionError: expected:<2002> but was:<0> at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.failNotEquals(Assert.java:743) at org.junit.Assert.assertEquals(Assert.java:118) at org.junit.Assert.assertEquals(Assert.java:555) at org.junit.Assert.assertEquals(Assert.java:542) at org.apache.mahout.text.SequenceFilesFromLuceneStorageMRJobTest.testRun(SequenceFilesFromLuceneStorageMRJobTest.java:73) Interesting thing about this one is the Test class has only a single test and it has no randomization. FWIW, it's also becoming increasingly clear to me that we need some notion of real integration tests that we can run against a Hadoop cluster (or at least a virtual Hadoop cluster). -Grant On Jun 8, 2013, at 9:38 AM, Dawid Weiss <dawid.we...@cs.put.poznan.pl> wrote: >> number generators. Where a test depends on a particular sequence, and >> somewhere an RNG doesn't use the "RandomUtils" trick, it may have a >> different state if other tests ran before. > > I have a different solution for this in randomizedtesting framework (a > Random instance cannot be shared from test to test, it will throw an > exception if you do share it). This doesn't solve all the possible > problems but proved quite effective at catching test dependencies. > >> The surefire parameter just controls what order the *classes* run in AFAICT: >> http://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#runOrder > > Yeah, I was on the train when I wrote that e-mail. The trick I > remembered is in fact inside JUnit 4.11 and onwards -- > https://github.com/junit-team/junit/blob/master/doc/ReleaseNotes4.11.md#test-execution-order > > D. -------------------------------------------- Grant Ingersoll | @gsingers http://www.lucidworks.com