Perl Auto Test
Wednesday, 4 February 2015
4. Writing test cases in array
Note: Using PERL Module- fib.pm from post 1
Test Program(t.pl):
use strict;
use warnings;
use Test::Simple tests => 3;
use fib;
my @arr=(
[1,1],
[4,0],
[8,1]
);
foreach(@arr)
{
my $exp=pop @$_;
my $act=fib(@$_);
ok($exp==$act);
}
Output of t.pl
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment