summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefano Lattarini <stefano.lattarini@gmail.com>2014-12-22 12:39:05 +0100
committerStefano Lattarini <stefano.lattarini@gmail.com>2014-12-22 13:35:33 +0100
commitcfc6916ef499014b71e874924f1077e8c0604f89 (patch)
tree3fe89578901792c620ee1aa922181d0bcaa260f7
parent3c72ada8d048c6d92a6fd323f6647c8e090dd7a6 (diff)
downloadautomake-cfc6916ef499014b71e874924f1077e8c0604f89.tar.gz
maint: make output of 'gen-testsuite-part' deterministic
So that diffs displayed by the 'compare-autodiffs' target are less spurious and more useful. * gen-testsuite-part: Sort keys of %deps_extractor, %wrapper_setups and %depmodes before iterating on them. Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
-rwxr-xr-xgen-testsuite-part8
1 files changed, 5 insertions, 3 deletions
diff --git a/gen-testsuite-part b/gen-testsuite-part
index 3bd5c9f01..32158bac2 100755
--- a/gen-testsuite-part
+++ b/gen-testsuite-part
@@ -297,8 +297,9 @@ foreach my $test (@all_tests)
$wrapper_setups{$test} = \@setups if @setups;
}
# And now create all the wrapper tests.
-while (my ($wrapped_test, $setup_list) = each %wrapper_setups)
+for my $wrapped_test (sort keys %wrapper_setups)
{
+ my $setup_list = $wrapper_setups{$wrapped_test};
(my $base = $wrapped_test) =~ s/\.([^.]*)$//;
my $suf = $1 or die "$me: test '$wrapped_test' lacks a suffix\n";
my $count = 0;
@@ -359,7 +360,7 @@ my %depmodes =
foreach my $lt (TRUE, FALSE)
{
- foreach my $m (keys %depmodes)
+ foreach my $m (sort keys %depmodes)
{
my $planned = ($lt && $m eq "auto") ? 84 : 28;
my @required =
@@ -414,8 +415,9 @@ print <<EOF;
EOF
-while (my ($k, $x) = each %deps_extractor)
+for my $k (sort keys %deps_extractor)
{
+ my $x = $deps_extractor{$k};
my $dist_prereqs = $x->{dist_prereqs} || "";
my $nodist_prereqs = $x->{nodist_prereqs} || "";
my @tests = grep { line_match $x->{line_matcher}, $_ } @all_tests;