Skip to content

Commit

Permalink
support smolder reports in harness and Makefile. Patch courtesy by jd…
Browse files Browse the repository at this point in the history
…v79++
  • Loading branch information
moritz committed Sep 19, 2009
1 parent 0d77e42 commit 2c40a5b
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
6 changes: 6 additions & 0 deletions build/Makefile.in
Expand Up @@ -298,6 +298,12 @@ t/spec :
spectest_update :
-cd t/spec && svn up

rakudo_test_run.tar.gz: testable t/spectest.data
- $(HARNESS_WITH_FUDGE_JOBS) --tests-from-file=t/spectest.data --archive rakudo_test_run.tar.gz --parrot_revision @revision@

spectest_smolder: rakudo_test_run.tar.gz
curl -F architecture=@cpuarch@ -F platform=@osname@ -F revision=`git log -1 --pretty=format:%H` -F report_file=@rakudo_test_run.tar.gz http://smolder.plusthree.com/app/public_projects/process_add_report/18

testable : perl6$(EXE) Test.pir spectest_checkout spectest_update

t/localtest.data:
Expand Down
16 changes: 14 additions & 2 deletions t/harness
Expand Up @@ -23,6 +23,8 @@ GetOptions(
'verbosity=i' => \$Test::Harness::verbose,
'jobs:3' => \my $jobs,
'icu:1' => \my $do_icu,
'archive=s' => \my $archive,
'parrot_revision=s' => \my $parrot_revision,
);

my @pass_through_options = grep m/^--?[^-]/, @ARGV;
Expand Down Expand Up @@ -54,14 +56,24 @@ if ($do_fudge) {
@tfiles = fudge(@tfiles);
}

if (eval { require TAP::Harness; 1 }) {
my $tap_harness_class = 'TAP::Harness';
$tap_harness_class .= '::Archive' if $archive;

my $extra_properties;
$extra_properties->{'Parrot Revision'} = $parrot_revision
if $parrot_revision;

if (eval "require $tap_harness_class;") {
my %harness_options = (
exec => ['./perl6'],
verbosity => 0+$Test::Harness::verbose,
jobs => $ENV{TEST_JOBS} || $jobs || 1,
ignore_exit => 1,
merge => 1,
$archive ? ( archive => $archive ) : (),
$extra_properties ? ( extra_properties => $extra_properties ) : (),
);
TAP::Harness->new( \%harness_options )->runtests(@tfiles);
$tap_harness_class->new( \%harness_options )->runtests(@tfiles);
}
else {
runtests(@tfiles);
Expand Down

0 comments on commit 2c40a5b

Please sign in to comment.