This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
make porting/cmp_version.t clearer what happens
authorDavid Mitchell <davem@iabyn.com>
Mon, 5 Jun 2017 11:32:12 +0000 (12:32 +0100)
committerDavid Mitchell <davem@iabyn.com>
Mon, 5 Jun 2017 11:44:12 +0000 (12:44 +0100)
Add some code comments, and include the version number its comparing
against in the output.

Porting/cmpVERSION.pl
t/porting/cmp_version.t

index 01f77c8..67e9b39 100755 (executable)
@@ -169,6 +169,7 @@ unless (%module_diffs) {
 }
 
 printf "1..%d\n" => scalar keys %module_diffs if $tap;
+print "#\n# Comparing against $tag_to_compare ....\n#\n" if $tap;
 
 my $count;
 my $diff_cmd = "git --no-pager diff $tag_to_compare ";
@@ -194,9 +195,14 @@ foreach my $pm_file (sort keys %module_diffs) {
         print "ok $count - $pm_file\n" if $tap;
     } else {
        if ($tap) {
+            print "#\n# " . '-' x 75 . "\n"
+            . "# Version number ($pm_version) unchanged since"
+            . " $tag_to_compare, but contents have changed:\n#\n";
            foreach (sort @{$module_diffs{$pm_file}}) {
                print "# $_" for `$diff_cmd $q$_$q`;
            }
+            print "# " . '-' x 75 . "\n";
+
            if (exists $skip_versions{$pm_file}
                and grep $pm_version eq $_, @{$skip_versions{$pm_file}}) {
                print "ok $count - SKIP $pm_file version $pm_version\n";
index bbbc852..18b3e57 100644 (file)
@@ -9,6 +9,13 @@
 # AND you should probably also nudge the upstream maintainer for
 # example by filing a bug, with a patch attached and linking to
 # the core change.
+#
+# This test script works by finding the last non-RC tagged commit,
+# which it assumes was the last release, then for each module:
+# if it has changed since that commit, but its version number is still the
+# same as that commit, report it.
+#
+# There's also a module exclusion list in Porting/cmpVERSION.pl.
 
 BEGIN {
     @INC = '..' if -f '../TestInit.pm';