11 use ExtUtils::MakeMaker;
13 use Test::More "no_plan";
15 my $is_of_type = \&ExtUtils::MakeMaker::_is_of_type;
23 [bless({}, "Foo"), "Foo", 1],
24 [bless({}, "Bar"), "Foo", 0],
25 [bless([], "Foo"), "", 0],
26 [bless([], "Foo"), "HASH", 0],
27 [bless([], "Foo"), "ARRAY", 1],
30 for my $test (@tests) {
31 my($thing, $type, $want) = @$test;
34 local $SIG{__DIE__} = sub { fail("sigdie should be ignored") };
35 is !!$is_of_type->($thing, $type), !!$want, qq[_is_of_type($thing, '$type'): $want];