Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion lib/Dobby/Boxmate/App/Command/ciplan.pm
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ sub _template_program {
[ newt_full => () ],
# [ cassandane => () ],
[ stop_services => () ],
[ log_gather => () ],
];
}

Expand Down
28 changes: 19 additions & 9 deletions misc/test-runner-on-vm
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,7 @@ sub STEP_cassandane ($self, @args) {
return;
}

sub STEP_log_gather ($self) {
sub gather_logs ($self) {
START("gathering logs");

my $root = $self->root;
Expand Down Expand Up @@ -487,21 +487,31 @@ my $testproc = TestProcess->new({

my @instructions = $plan->{program}->@*;

for my $instruction (@instructions) {
my ($name, @args) = @$instruction;
eval {
for my $instruction (@instructions) {
my ($name, @args) = @$instruction;

my $method = "STEP_$name";
my $method = "STEP_$name";

unless ($testproc->can($method)) {
# XXX: validate all this before starting any work!
die "Test runner has no implementation for $name step\n";
unless ($testproc->can($method)) {
# XXX: validate all this before starting any work!
die "Test runner has no implementation for $name step\n";
}

$testproc->$method(@args);
}
};

$testproc->$method(@args);
}
my $error = $@;

FINISH_CURR();

$self->gather_logs;

if ($error) {
die $error;
}

if ($testproc->is_passing) {
say "All tests successful!";
exit 0;
Expand Down
Loading