Subject: | Test::Deep breaks ->isa() |
Test::Deep causes main->isa('Foo') to return true. The attached script
produces the following output:
1..2
ok 1 - 'main' is not a 'Foo' before using Test::Deep
not ok 2 - 'main' should not be a 'Foo' after using Test::Deep
# Failed test ''main' should not be a 'Foo' after using Test::Deep'
# at ./bug.pl line 14.
# 'main->isa('Foo')' yields: Test::Deep::Isa=HASH(0x10194378)
# Looks like you failed 1 test of 2.
This problem was identified in: http://www.cpanforum.com/threads/4765
Subject: | test_deep_isa_bug.pl |
#!/usr/bin/perl
use strict;
use warnings;
use Test::More tests => 2;
BEGIN {
ok(! main->isa('Foo'), q/'main' is not a 'Foo' before using Test::Deep/);
}
use Test::Deep;
ok(! main->isa('Foo'), q/'main' should not be a 'Foo' after using Test::Deep/);
diag("'main->isa('Foo')' yields: " . main->isa('Foo'));
# EOF