Commit 985b376f authored by Christian Fibich's avatar Christian Fibich Committed by Stefan Tauner
Browse files

Allow user to specify number of repetitions of Sequence Tests

parent 9d8e857d
......@@ -865,6 +865,18 @@ BEGIN {
depends_on => "REPEAT",
help => "Specify an offset for all repetitions except the first"
},
REPEAT_NUM => {
description => "Number of repetitions",
ini_name => "REPEAT_NUM",
default => 0,
type => 'natural',
phases_opt => [qw(manual)],
gui_modes => [qw (auto)],
order => 14,
depends_on => "REPEAT",
help => "Specify a number of repetitions"
},
HALT_ON_UART_ERROR => {
ini_name => "HALT_ON_UART_ERROR",
default => 1,
......
......@@ -183,6 +183,8 @@ sub download_auto ($) {
return $recv_msg if (ref($recv_msg) ne "HASH");
$logger->info("Test $ti: Underrun occurred.") if ($recv_msg->{'underrun_occurred'});
push @tests, @{$fiji_tests->{'tests'}}[$ti];
my $check = $self->_check_halt($recv_msg);
......@@ -203,9 +205,14 @@ sub download_auto ($) {
if ($fiji_tests->{'design'}->{'REPEAT'} == 0) {
last;
} else {
$toff = $fiji_tests->{'design'}->{'REPEAT_OFFSET'};
$logger->info("Repeat tests beginning with $toff.");
$ri++;
if ($fiji_tests->{'design'}->{'REPEAT_NUM'} > 0 && $fiji_tests->{'design'}->{'REPEAT_NUM'} == $ri) {
$logger->info("Specified number of repetitions executed");
last;
} else {
$toff = $fiji_tests->{'design'}->{'REPEAT_OFFSET'};
$logger->info("Repeat tests beginning with $toff.");
}
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment