Continuum

intermittent (machine wise) test failure on trunk

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.1-beta-1
  • Fix Version/s: 1.1-beta-2
  • Component/s: Core - Profiles
  • Labels:
    None
  • Complexity:
    Intermediate
  • Number of attachments :
    0

Description

I have been noticing an odd test case that has been failing on certain machines but have been unable to reproduce it locally on my dev box.

Working on a fresh installation on a friends machine I was able to find and maybe isolate the error with some more output.

Maybe the profile work lately has caused this to happen but some of us have something installed in our local repo's that suppress the problem. It looks to me that the creation of a project with a bogus module definition is adding an additional error to the building results on these machines and with this output we can see that its not the /test-classes/projects/continuum/pom.xml artifact causing the problem but the I'm-not-here-project one.

I am making this issue so we have a bit of a record on it and maybe we can track down why this doesn't manifest on installations such as mine (and I think emm as well)

[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-core/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-model/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-plexus-application/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-web/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-xmlrpc/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/continuum-notifiers/pom.xml
[INFO] Downloading file:/home/jjchapman/src/trunks/continuum/continuum-core/targ
et/test-classes/projects/continuum/I'm-not-here-project/pom.xml
add.project.artifact.not.found.error
add.project.missing.pom.error

[ stderr ] ---------------------------------------------------------------

[ stacktrace ] -----------------------------------------------------------

junit.framework.AssertionFailedError: expected:<1> but was:<2>
at junit.framework.Assert.fail(Assert.java:47)
at junit.framework.Assert.failNotEquals(Assert.java:282)
at junit.framework.Assert.assertEquals(Assert.java:64)
at junit.framework.Assert.assertEquals(Assert.java:201)
at junit.framework.Assert.assertEquals(Assert.java:207)
at org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumPro
jectBuilderTest.testCreateProjectsWithModules(MavenTwoContinuumProjectBuilderTes
t.java:200)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.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 sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)

Activity

Hide
Wendy Smoak added a comment -

Not sure if this is related, but I can't build trunk either:

$ mvn -version
Maven version: 2.0.7
Java version: 1.5.0_07
OS name: "mac os x" version: "10.4.10" arch: "i386"

$mvn install
...
Failed tests:
testCreateProjectsWithModules(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest)
testCreateProjectsWithModuleswithParentPomIsntPomXml(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest)
testCreateProjectWithoutModules(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest)

Tests in error:
testSuccessfulBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest)
testFailedBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest)
testErrorenousBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest)
testgetDefaultJdkInformations(org.apache.maven.continuum.installation.DefaultInstallationServiceTest)
testgetJdkInformations(org.apache.maven.continuum.installation.DefaultInstallationServiceTest)
testgetJdkInformationsWithCommonMethod(org.apache.maven.continuum.installation.DefaultInstallationServiceTest)

Tests run: 54, Failures: 3, Errors: 6, Skipped: 0

Show
Wendy Smoak added a comment - Not sure if this is related, but I can't build trunk either: $ mvn -version Maven version: 2.0.7 Java version: 1.5.0_07 OS name: "mac os x" version: "10.4.10" arch: "i386" $mvn install ... Failed tests: testCreateProjectsWithModules(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest) testCreateProjectsWithModuleswithParentPomIsntPomXml(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest) testCreateProjectWithoutModules(org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilderTest) Tests in error: testSuccessfulBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest) testFailedBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest) testErrorenousBuild(org.apache.maven.continuum.notification.mail.MailContinuumNotifierTest) testgetDefaultJdkInformations(org.apache.maven.continuum.installation.DefaultInstallationServiceTest) testgetJdkInformations(org.apache.maven.continuum.installation.DefaultInstallationServiceTest) testgetJdkInformationsWithCommonMethod(org.apache.maven.continuum.installation.DefaultInstallationServiceTest) Tests run: 54, Failures: 3, Errors: 6, Skipped: 0
Hide
Olivier Lamy added a comment -

Concerning mac, I think failure in DefaultInstallationServiceTest is due to missing env var JAVA_HOME on mac.
Wendy : can you test with adding an env var JAVA_HOME ?
IMO, in case of missing env var we must switch to System.getProperty("java.home").

Show
Olivier Lamy added a comment - Concerning mac, I think failure in DefaultInstallationServiceTest is due to missing env var JAVA_HOME on mac. Wendy : can you test with adding an env var JAVA_HOME ? IMO, in case of missing env var we must switch to System.getProperty("java.home").
Hide
Christian Gruber added a comment -

Tried it on my mac, and I still get the three failures. All the errors went away after defining JAVA_HOME and M2_HOME. Just the three failures.

Show
Christian Gruber added a comment - Tried it on my mac, and I still get the three failures. All the errors went away after defining JAVA_HOME and M2_HOME. Just the three failures.
Hide
Jesse McConnell added a comment -

seems to me that the test case is just wrong, that the profile work altered the test case behavior...

what I don't understand is why certain of us don't have the behavior exhibited like it is...

Show
Jesse McConnell added a comment - seems to me that the test case is just wrong, that the profile work altered the test case behavior... what I don't understand is why certain of us don't have the behavior exhibited like it is...
Hide
Jesse McConnell added a comment -

svn commit: r561907

there was a 1.1-SNAPSHOT parent reference in a test pom...and when we left the 1.1-SNAPSHOT version it started failing if you didn't have that 1.1-SNAPSHOT continuum parent version in your local repo

changed it to 1.0.3 so this shouldn't happen again...all the others were fine, looks like this one was missed sometime in the past

Show
Jesse McConnell added a comment - svn commit: r561907 there was a 1.1-SNAPSHOT parent reference in a test pom...and when we left the 1.1-SNAPSHOT version it started failing if you didn't have that 1.1-SNAPSHOT continuum parent version in your local repo changed it to 1.0.3 so this shouldn't happen again...all the others were fine, looks like this one was missed sometime in the past

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: