IMPORTANT: JAC is a Public system and anyone on the internet will be able to view the data in the created JAC tickets. Please don’t include Customer or Sensitive data in the JAC ticket.
Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-15496

Build is successful when Maven fails and tests are quarantined

      Problem

      Build is successful when Maven fails and tests are quarantined. It looks like using the 'Use Maven return code' feature is not working when used with quarantined tests. In the example below, Maven returned an error code but it looks like Bamboo ignored it, maybe mistaking it for a failed test.

      Steps to reproduce

      Make sure that Maven tasks have 'Use Maven return code' checked. Run a build with quarantined tests.

      // this is correct
      simple	23-Jan-2015 14:03:31	Failing task since return code of [/opt/maven-3.2/bin/mvn -Djava.io.tmpdir=/tmp/AMDN-AMDNRELEASE-JOB1 release:perform --batch-mode -DignoreSnapshots=true -Dresume=false] was 1 while expected 0
      simple	23-Jan-2015 14:03:31	Parsing test results under /mnt/bamboo-ebs/bamboo-agent/build-dir/AMDN-AMDNRELEASE-JOB1...
      simple	23-Jan-2015 14:03:31	Injected variable bamboo.mvn.release.releaseVersion=0.6.38 in RESULT scope
      // this is not correct: all tests pass but maven had an error and did not produce any artifact
      simple	23-Jan-2015 14:03:31	Changing Task Result to SUCCESS as all failed tests were quarantined.
      

      Bamboo detects the task is failing (1st line of the exemple above), but doesn't mark the whole build as failed.

            Loading...
            IMPORTANT: JAC is a Public system and anyone on the internet will be able to view the data in the created JAC tickets. Please don’t include Customer or Sensitive data in the JAC ticket.
            Uploaded image for project: 'Bamboo Data Center'
            1. Bamboo Data Center
            2. BAM-15496

            Build is successful when Maven fails and tests are quarantined

                Problem

                Build is successful when Maven fails and tests are quarantined. It looks like using the 'Use Maven return code' feature is not working when used with quarantined tests. In the example below, Maven returned an error code but it looks like Bamboo ignored it, maybe mistaking it for a failed test.

                Steps to reproduce

                Make sure that Maven tasks have 'Use Maven return code' checked. Run a build with quarantined tests.

                // this is correct
                simple	23-Jan-2015 14:03:31	Failing task since return code of [/opt/maven-3.2/bin/mvn -Djava.io.tmpdir=/tmp/AMDN-AMDNRELEASE-JOB1 release:perform --batch-mode -DignoreSnapshots=true -Dresume=false] was 1 while expected 0
                simple	23-Jan-2015 14:03:31	Parsing test results under /mnt/bamboo-ebs/bamboo-agent/build-dir/AMDN-AMDNRELEASE-JOB1...
                simple	23-Jan-2015 14:03:31	Injected variable bamboo.mvn.release.releaseVersion=0.6.38 in RESULT scope
                // this is not correct: all tests pass but maven had an error and did not produce any artifact
                simple	23-Jan-2015 14:03:31	Changing Task Result to SUCCESS as all failed tests were quarantined.
                

                Bamboo detects the task is failing (1st line of the exemple above), but doesn't mark the whole build as failed.

                        Unassigned Unassigned
                        brosa Bruno Rosa
                        Votes:
                        1 Vote for this issue
                        Watchers:
                        6 Start watching this issue

                          Created:
                          Updated:
                          Resolved:

                            Unassigned Unassigned
                            brosa Bruno Rosa
                            Affected customers:
                            1 This affects my team
                            Watchers:
                            6 Start watching this issue

                              Created:
                              Updated:
                              Resolved: