Bug#711446: [PATCH 2/2] Tests: Sort the keywords in the graph output

Ian Jackson ijackson at chiark.greenend.org.uk
Sat Feb 8 17:56:03 UTC 2014


They come out in hash order which is not necessarily stable.
Fixes FTBFS with perl 5.18 (Debian #711446, CPAN #85950).

Signed-off-by: Ian Jackson <ijackson at chiark.greenend.org.uk>
---
 t/TestUtils.pl |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/t/TestUtils.pl b/t/TestUtils.pl
index 4fec3d3..9338667 100644
--- a/t/TestUtils.pl
+++ b/t/TestUtils.pl
@@ -3,6 +3,11 @@ sub launder ($) {
     my ($gr) = @_;
     # Ignore font-sizes, it's system-dependant
     $$gr =~ s/\d+/0/g;
+    # Sort the keywords in the graph output, as they come out
+    # in hash order which isn't necessarily stable.
+    $$gr =~ s{((?:\s+.*\n)+)}{
+        join "\n", sort split /\n/, $1
+    }ge;
 }
 
 1;
-- 
1.7.10.4



More information about the pkg-perl-maintainers mailing list