several testcases for perl

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10403 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Robert Stone 2008-04-30 21:02:46 +00:00
commit 8b713d759d
53 changed files with 2037 additions and 486 deletions

View file

@ -1,15 +1,12 @@
use strict;
use warnings;
use Test::More tests => 5;
BEGIN { use_ok('multiple_inheritance') }
require_ok('multiple_inheritance');
use multiple_inheritance;
my $fooBar = new multiple_inheritance::FooBar();
is($fooBar->foo(), 2, "Runtime test1");
$fooBar = new multiple_inheritance::FooBar();
if ($fooBar->foo() != 2) {
die "Runtime test1 failed\n";
}
is($fooBar->bar(), 1, "Runtime test2");
if ($fooBar->bar() != 1) {
die "Runtime test2 failed\n";
}
if ($fooBar->fooBar() != 3) {
die "Runtime test3 failed\n";
}
is($fooBar->fooBar(), 3, "Runtime test3 ");