[libcode-tidyall-perl] 12/374: 1 or 2 backups

Jonas Smedegaard js at alioth.debian.org
Sun Sep 29 22:25:40 UTC 2013


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

js pushed a commit to branch master
in repository libcode-tidyall-perl.

commit 543f950840e46fd68ad825272d10dfd44183761c
Author: Jonathan Swartz <swartz at pobox.com>
Date:   Tue Jun 12 11:38:55 2012 -0700

    1 or 2 backups
---
 lib/Code/TidyAll/t/Basic.pm |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/Code/TidyAll/t/Basic.pm b/lib/Code/TidyAll/t/Basic.pm
index 7e16402..598a26a 100644
--- a/lib/Code/TidyAll/t/Basic.pm
+++ b/lib/Code/TidyAll/t/Basic.pm
@@ -84,7 +84,6 @@ sub test_caching_and_backups : Tests {
 
     $go->();
     is( $output, '', 'no output' );
-    sleep(1);    # to get two backup files
 
     write_file( $file, "def" );
     $go->();
@@ -94,7 +93,7 @@ sub test_caching_and_backups : Tests {
     my $backup_dir = $ct->data_dir . "/backups";
     my @files;
     find( { follow => 0, wanted => sub { push @files, $_ if -f }, no_chdir => 1 }, $backup_dir );
-    is( scalar(@files), 2, "2 backup files" );
+    ok( scalar(@files) == 1 || scalar(@files) == 2, "1 or 2 backup files" );
     foreach my $file (@files) {
         like( $file, qr|\.tidyall\.d/backups/foo\.txt-\d+-\d+\.bak|, "backup filename" );
     }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libcode-tidyall-perl.git



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