Author: jkeenan
Date: Mon Mar 24 18:57:33 2008
New Revision: 26530

Modified:
   trunk/t/manifest/01-basic.t
   trunk/t/manifest/02-regenerate_file.t
   trunk/t/manifest/03-regenerate_skip.t
   trunk/t/manifest/04-alt_file.t
   trunk/t/manifest/05-alt_skip.t

Log:
Skip all manifest tools tests when not working in a checkout from the 
repository.  All our manifest-generating tools depend on running version 
control functions.  Hence, there's no point in trying to generate a MANIFEST in 
a release version and no point in testing the MANIFEST-generating tools in a 
release version.

Modified: trunk/t/manifest/01-basic.t
==============================================================================
--- trunk/t/manifest/01-basic.t (original)
+++ trunk/t/manifest/01-basic.t Mon Mar 24 18:57:33 2008
@@ -6,7 +6,10 @@
 use strict;
 use warnings;
 
-use Test::More tests => 11;
+use Test::More;
+plan( skip_all => "\nRelevant only when working in checkout from repository" )
+    unless (-e 'DEVELOPING');
+plan( tests => 13 );
 use Carp;
 use Cwd;
 use File::Temp qw( tempdir );
@@ -20,12 +23,10 @@
 my $mani = Parrot::Manifest->new( { script => $script, } );
 isa_ok( $mani, 'Parrot::Manifest' );
 
-# RT#51860: this fails in a downloaded release
-#ok( scalar( @{ $mani->{dirs} } ),
-    #"Parrot::Manifest constructor used 'status' command to find at least 1 
directory." );
-# RT#51860: this fails in a downloaded release
-#ok( scalar( @{ $mani->{versioned_files} } ),
-    #"Parrot::Manifest constructor used 'status' command to find at least 1 
versioned file." );
+ok( scalar( @{ $mani->{dirs} } ),
+    "Parrot::Manifest constructor used 'status' command to find at least 1 
directory." );
+ok( scalar( @{ $mani->{versioned_files} } ),
+    "Parrot::Manifest constructor used 'status' command to find at least 1 
versioned file." );
 
 my $manifest_lines_ref = $mani->prepare_manifest();
 is( ref($manifest_lines_ref), q{HASH}, "prepare_manifest() returned hash ref" 
);

Modified: trunk/t/manifest/02-regenerate_file.t
==============================================================================
--- trunk/t/manifest/02-regenerate_file.t       (original)
+++ trunk/t/manifest/02-regenerate_file.t       Mon Mar 24 18:57:33 2008
@@ -6,7 +6,10 @@
 use strict;
 use warnings;
 
-use Test::More tests => 11;
+use Test::More;
+plan( skip_all => "\nRelevant only when working in checkout from repository" )
+    unless (-e 'DEVELOPING');
+plan( tests => 12 );
 use Carp;
 use Cwd;
 use File::Copy;
@@ -37,8 +40,7 @@
         or croak "Unable to copy $f to tempdir";
     ok( -f $f, "$f found in tempdir" );
     my $need_for_file = 
$mani->determine_need_for_manifest($manifest_lines_ref);
-    # RT#51860: this fails in a downloaded release
-    #ok( !$need_for_file, "No need to regenerate $f" );
+    ok( !$need_for_file, "No need to regenerate $f" );
     chdir $cwd
         or croak "Unable to change back from temporary directory after 
testing";
     unlink qq{$tdir/$f} or croak "Unable to delete file from tempdir";

Modified: trunk/t/manifest/03-regenerate_skip.t
==============================================================================
--- trunk/t/manifest/03-regenerate_skip.t       (original)
+++ trunk/t/manifest/03-regenerate_skip.t       Mon Mar 24 18:57:33 2008
@@ -6,7 +6,10 @@
 use strict;
 use warnings;
 
-use Test::More tests => 9;
+use Test::More;
+plan( skip_all => "\nRelevant only when working in checkout from repository" )
+    unless (-e 'DEVELOPING');
+plan( tests => 10 );
 use Carp;
 use Cwd;
 use File::Copy;
@@ -36,8 +39,7 @@
         or croak "Unable to copy $sk to tempdir";
     ok( -f $sk, "$sk found in tempdir" );
     my $need_for_skip = $mani->determine_need_for_manifest_skip($print_str);
-    # RT#51860 this fails in a downloaded release
-    #ok( !$need_for_skip, "No need to regenerate $sk" );
+    ok( !$need_for_skip, "No need to regenerate $sk" );
     unlink qq{$tdir/$sk} or croak "Unable to delete file from tempdir";
     chdir $cwd
         or croak "Unable to change back from temporary directory after 
testing";

Modified: trunk/t/manifest/04-alt_file.t
==============================================================================
--- trunk/t/manifest/04-alt_file.t      (original)
+++ trunk/t/manifest/04-alt_file.t      Mon Mar 24 18:57:33 2008
@@ -6,7 +6,10 @@
 use strict;
 use warnings;
 
-use Test::More tests => 6;
+use Test::More;
+plan( skip_all => "\nRelevant only when working in checkout from repository" )
+    unless (-e 'DEVELOPING');
+plan( tests =>  6 );
 use Carp;
 use lib (qw| lib |);
 use_ok('Parrot::Manifest');

Modified: trunk/t/manifest/05-alt_skip.t
==============================================================================
--- trunk/t/manifest/05-alt_skip.t      (original)
+++ trunk/t/manifest/05-alt_skip.t      Mon Mar 24 18:57:33 2008
@@ -6,7 +6,10 @@
 use strict;
 use warnings;
 
-use Test::More tests => 6;
+use Test::More;
+plan( skip_all => "\nRelevant only when working in checkout from repository" )
+    unless (-e 'DEVELOPING');
+plan( tests =>  6 );
 use Carp;
 use lib (qw| lib |);
 use_ok('Parrot::Manifest');

Reply via email to