X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2Frgit.git;a=blobdiff_plain;f=t%2F20-each.t;h=1c582464dcd9a9b566e66a2a0abd95b15b4ebf0a;hp=4180a933335cbc58702aa957440ea7cd4b656a32;hb=29a833290906751334d87b58cbdb8ede4134c6e1;hpb=67e585ffae69ce0c350a920658738d7864b1d54a diff --git a/t/20-each.t b/t/20-each.t index 4180a93..1c58246 100644 --- a/t/20-each.t +++ b/t/20-each.t @@ -7,7 +7,7 @@ use Cwd qw/cwd abs_path/; use File::Spec::Functions qw/catdir catfile/; use File::Temp qw/tempfile tempdir/; -use Test::More tests => 2 + 3 * 2; +use Test::More tests => 2 + 2 * 2 + 11 * (3 + 1); use App::Rgit; @@ -106,5 +106,15 @@ for my $cmd (qw/commit FAIL/) { my @lines = split /\n/, do { local $/; <$fh> }; my $res = [ map [ split /\|/, $_ ], @lines ]; my $exp = [ map [ $cmd, @$_ ], $fail ? $expected[0] : @expected ]; - is_deeply($res, $exp, "each $cmd did the right thing"); + for my $i (0 .. $#$exp) { + my $e = $exp->[$i]; + my $r = shift @$res; + isnt($r, undef, "each $cmd visited repository $i"); +SKIP: + { + skip 'didn\'t visited that repo' => 10 unless defined $r; + is($r->[$_], $e->[$_], "each $cmd argument $_ for repository $i is ok") + for 0 .. 9; + } + } }