diff options
author | Nicholas Clark <nick@ccl4.org> | 2011-09-10 06:08:21 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2011-09-10 06:43:49 -0700 |
commit | 5e0b4493cc341303b7c3c0606ba927b605e53a62 (patch) | |
tree | 3ee4fd072e252a2a4da26bac1ca189b74376e2d5 /t | |
parent | e476d66f344c36301762d51eed5338b862f3cc4d (diff) | |
download | perl-5e0b4493cc341303b7c3c0606ba927b605e53a62.tar.gz |
Tweaks to tie_fetch_count.t
Improve error diagnostics by reporting the caller's line number if
check_count() fails, and correct a thinko in a test description.
Diffstat (limited to 't')
-rw-r--r-- | t/op/tie_fetch_count.t | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/t/op/tie_fetch_count.t b/t/op/tie_fetch_count.t index 5903377180..d55ab5099e 100644 --- a/t/op/tie_fetch_count.t +++ b/t/op/tie_fetch_count.t @@ -28,6 +28,7 @@ sub STORE { unshift @{$_[0]}, $_[1] } sub check_count { my $op = shift; my $expected = shift() // 1; + local $::Level = $::Level + 1; is $count, $expected, "FETCH called " . ( $expected == 1 ? "just once" : @@ -223,7 +224,7 @@ eval { chdir $var8 } ; check_count 'chdir $tied_glob'; $var8 = *dummy; $dummy = $var8; $count = 0; eval { chmod 0, $var8 } ; check_count 'chmod 0,$tied_glob'; $var8 = *dummy; $dummy = $var8; $count = 0; -eval { chown 0,0,$var8 }; check_count 'chmod 0,$tied_glob'; +eval { chown 0,0,$var8 }; check_count 'chown 0,0,$tied_glob'; ############################################### |