Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
  • Community
  • Products
  • Bamboo
  • Questions
  • All the tests passed, but bamboo build fails with a statement "No failed tests found, a possible compilation error occurred."

All the tests passed, but bamboo build fails with a statement "No failed tests found, a possible compilation error occurred."

Yekkanti Kishore July 16, 2012

Hi,

I'm suppose to run some jbehave(automated) tests in bamboo. Once the tests run i'll generate some junit compatible xml files so that bamboo could understand the same. All the jbehave tests are ran as part of a script, because i need to run the jbehave tests in a seperate screen. Example script is as follows.

Ex: export DISPLAY=:0 && xvfb-run --server-args="-screen 0, 1024x768x24" mvn clean integration-test -DskipTests -P integration-test -Dtest=*

I have one more junit parser task which points to the generated xml files. So, once the bamboo build runs and even if all the tests pass, i get red build with the message "No failed tests found, a possible compilation error occurred."

Can somone please help me on this regard.

3 answers

1 accepted

1 vote
Answer accepted
Yekkanti Kishore July 19, 2012
Turns out to be a simple fix.

General bamboo behavior is to scan the entire log and see for any failure codes(1). For this specific configuration i had some 6 scripts out of which one of them was to kill the xvfb(frame buffer). For some reason server is not able to kill xvfb and that task was returning a failure code. Because of this, though all the tests passed, bamboo got one of this error codes from previous tasks and build was failing.

Current fix is to remove the task which kills xvfb and the build went green! \o/.
1 vote
Radu Dumitriu
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 16, 2012

Not an expert in bamboo, but most such errors occur because the script does not exit with 0, so bamboo marks it as failed.

Yekkanti Kishore July 16, 2012

Yep in my case i was not using any maven task ny default. All of my tasks are the "command" script tasks and i execute even teh maven command using the script. I can see couple of stack traces in the log(which are not affecting my tests any way). I guess, bamboo by default will scan the logs(if i'm not using maven tasks) and looks at those stack traces and assume that there is possibel compilation error. I basically want how i can over come this, because bamboo was able to read my test reports and it knows all of my tests are passed.

0 votes
Przemek Bruski
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 17, 2012

The most likely cause for this problem is that the xml files are not found (or cannot be parsed due to an invalid format). What path are you using to specify xml files location?

Yekkanti Kishore July 17, 2012

Actually, Bamboo is able to find the xml files and generates a good report. Please look at https://ci.openmrs.org/browse/FUNC-APPTEST/latest. You can see that bamboo found and succesfully parsed 26 files( I have only 26 tests in the application) and hence it says 26 tests passed.

PiotrA
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 17, 2012

Hm... is it possible that there are (apart of those valid 26 .xml files) also other .xml files in the same path? I was wondering if there could be some temporary 27th .xml file with invalid format generated that would trick Bamboo's junit parser to think there is a "compilaction error"...

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events