|
This is my test class and following error message cooures, how to solve it , pls help me
---------------------code-----------------------------
package first_example;
use strict;
use employee;
use Test::Unit::Debug qw(debug debugged);
use Test::Unit::TestSuite;
use base qw(Test::Unit::TestCase);
sub test_ok {
my $self = shift();
$self->assert(23 == 23);
}
sub test_fail {
my $self = shift();
my $result1 ='Tharinda1' ;
my $result = 'Tharinda';
$self->assert_not_equals($result,$result1);
$self->assert_equals($result,$result1);
}
sub set_up {
my $self = shift()->SUPER::set_up(@_);
}
sub tear_down {
my $self = shift();
$self->SUPER::tear_down(@_)
}
sub suite {
my $testsuite = Test::Unit::TestSuite->new(__PACKAGE__);
my $wrapper = fail_example_testsuite_setup->new($testsuite);
return $wrapper;
}
1;
package fail_example_testsuite_setup;
# this suite will decorate fail_example with additional fixture
use strict;
use Test::Unit::Debug qw(debug);
use base qw(Test::Unit::Setup);
sub set_up {
my $self = shift()->SUPER::set_up(@_);
debug("fail_example_testsuite_setup\n");
}
sub tear_down {
my $self = shift();
debug("fail_example_testsuite_tear_down\n");
$self->SUPER::tear_down(@_);
}
1;
-----------------error message--------------------------
gayan@21cnedc23>>/iw-home/iw-perl/bin/perl TestRunner.pl first_example.pm
Warning: Use of "require" without parentheses is ambiguous at (eval 11) line 1.
Suite class first_example.pm not found: Bareword "pm" not allowed while "strict subs" in use at (eval 11) line 1.
|
|
|
|
|
|
|
// |