Commit | Line | Data |
183ac38d |
1 | #!perl -wT |
2 | |
3 | use Test::More tests => 3; |
4 | use strict; |
5 | use_ok('Devel::InnerPackage'); |
6 | Bar->whee; |
7 | is_deeply([Devel::InnerPackage::list_packages("Bar")],[], "Don't pick up ::SUPER pseudo stash"); |
8 | is_deeply([Devel::InnerPackage::list_packages("Foo")],['Foo::Bar'], "Still pick up other inner package"); |
9 | |
10 | package Foo; |
11 | |
12 | sub whee { |
13 | 1; |
14 | } |
15 | |
16 | package Foo::Bar; |
17 | |
18 | sub whee {} |
19 | |
20 | package Bar; |
21 | use base 'Foo'; |
22 | |
23 | sub whee { |
24 | shift->SUPER::whee; |
25 | 2; |
26 | } |
27 | |
28 | |
29 | 1; |