From: Jesse Luehrs Date: Sat, 13 Nov 2010 15:56:18 +0000 (-0600) Subject: a few more tests X-Git-Tag: 0.14~36 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c5e221f901796575c6beba3a887e92473577528f;p=gitmo%2FPackage-Stash-XS.git a few more tests --- diff --git a/t/20-leaks.t b/t/20-leaks.t index 124e49e..4e48bd3 100644 --- a/t/20-leaks.t +++ b/t/20-leaks.t @@ -119,14 +119,16 @@ use Symbol; no_leaks_ok { $foo->get_or_add_package_symbol('io'); $foo->get_or_add_package_symbol('%hash'); - # and why are these not leaks either? - $foo->get_or_add_package_symbol('@array_init'); + my @super = ('Exporter'); + @{$foo->get_or_add_package_symbol('@ISA')} = @super; $foo->get_or_add_package_symbol('$glob'); } "get_or_add_package_symbol doesn't leak"; ok($foo->has_package_symbol('$glob')); is(ref($foo->get_package_symbol('$glob')), 'SCALAR'); - ok($foo->has_package_symbol('@array_init')); - is(ref($foo->get_package_symbol('@array_init')), 'ARRAY'); + ok($foo->has_package_symbol('@ISA')); + is(ref($foo->get_package_symbol('@ISA')), 'ARRAY'); + is_deeply($foo->get_package_symbol('@ISA'), ['Exporter']); + isa_ok('Foo', 'Exporter'); } {