steals python directors and adapts to perl5
This commit is contained in:
parent
c151a0d69a
commit
0901a3e867
23 changed files with 1741 additions and 5 deletions
21
Examples/test-suite/perl5/director_enum_runme.pl
Normal file
21
Examples/test-suite/perl5/director_enum_runme.pl
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
use strict;
|
||||
use warnings;
|
||||
use Test::More tests => 5;
|
||||
BEGIN { use_ok 'director_enum' }
|
||||
require_ok 'director_enum';
|
||||
|
||||
{
|
||||
package MyFoo;
|
||||
use base 'director_enum::Foo';
|
||||
sub say_hi { my($self, $val) = @_;
|
||||
return $val;
|
||||
}
|
||||
}
|
||||
|
||||
my $b = director_enum::Foo->new();
|
||||
isa_ok $b, 'director_enum::Foo';
|
||||
my $a = MyFoo->new();
|
||||
isa_ok $a, 'MyFoo';
|
||||
|
||||
is $a->say_hi($director_enum::hello),
|
||||
$a->say_hello($director_enum::hi);
|
||||
Loading…
Add table
Add a link
Reference in a new issue