[libgraph-writer-graphviz-perl] 03/05: Tests: Sort the keywords in the graph output

gregor herrmann gregoa at debian.org
Sat Feb 8 19:57:42 UTC 2014


This is an automated email from the git hooks/post-receive script.

gregoa pushed a commit to annotated tag debian/0.11-1nmu1
in repository libgraph-writer-graphviz-perl.

commit c0818e59eab55ace2b177d0ea88682c81d2830aa
Author: Ian Jackson <ijackson at chiark.greenend.org.uk>
Date:   Sat Feb 8 17:22:45 2014 +0000

    Tests: Sort the keywords in the graph output
    
    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;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libgraph-writer-graphviz-perl.git



More information about the Pkg-perl-cvs-commits mailing list