TAP::Formatter::Bamboo - Harness output delegate for Atlassian's Bamboo CI server
On the command line, with prove:
prove --formatter TAP::Formatter::Bamboo ...
Or, in your own scripts:
use TAP::Harness; my $harness = TAP::Harness->new( { formatter_class => 'TAP::Formatter::Bamboo', merge => 1, } ); $harness->runtests(@tests);
TAP::Formatter::Bamboo provides JUnit output formatting for TAP::Harness, which can be used in Atlassian's Bamboo CI server.
TAP::Formatter::Bamboo
TAP::Harness
This module is based on TAP::Formatter::JUnit by Graham TerMarsch <cpan@howlingfrog.com>, main differences are:
if environment variable TAP_FORMATTER_BAMBOO_OUTFILE is present then it will be used as filepath for output XML (otherwise "results.xml file will be created in current directory)
information about passing/failing tests is put to the STDOUT/STDERR respectively, so it can be watched in Bamboo's build logs (also live during build)
output of failed tests is saved in 'failure' tag, as Bamboo doesn't care about 'system-out' and 'system-err' tags (but shows content of 'failure')
short information about failure reason is put in the first line of 'failure' tag
Over-ridden open_test() method.
open_test()
Creates a TAP::Formatter::Bamboo::Session session, instead of a console formatter session.
TAP::Formatter::Bamboo::Session
Save resulting XML in results.xml file.
Piotr Piatkowski <pp@idea7.pl>
Graham TerMarsch <cpan@howlingfrog.com> (original TAP::Formatter::JUnit)
TAP::Formatter::JUnit
Credits from the original module:
Many thanks to Andy Armstrong et al. for the fabulous set of tests in Test::Harness; they became the basis for the unit tests here.
Test::Harness
Other thanks go out to those that have provided feedback, comments, or patches:
Mark Aufflick Joe McMahon Michael Nachbaur Marc Abramowitz Colin Robertson Phillip Kimmey Dave Lambley
This is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
TAP::Formatter::JUnit, TAP::Formatter::Console, http://confluence.atlassian.com/display/BAMBOO/JUnit+parsing+in+Bamboo.
To install TAP::Formatter::Bamboo, copy and paste the appropriate command in to your terminal.
cpanm
cpanm TAP::Formatter::Bamboo
CPAN shell
perl -MCPAN -e shell install TAP::Formatter::Bamboo
For more information on module installation, please visit the detailed CPAN module installation guide.