Lines 10-16
use POSIX qw(strftime);
Link Here
|
10 |
|
10 |
|
11 |
use C4::Bookseller qw( GetBookSellerFromId ); |
11 |
use C4::Bookseller qw( GetBookSellerFromId ); |
12 |
|
12 |
|
13 |
use Test::More tests => 42; |
13 |
use Test::More tests => 41; |
14 |
|
14 |
|
15 |
BEGIN { |
15 |
BEGIN { |
16 |
use_ok('C4::Acquisition'); |
16 |
use_ok('C4::Acquisition'); |
Lines 43-49
SKIP: {
Link Here
|
43 |
my $testorder = @$orders[0]; |
43 |
my $testorder = @$orders[0]; |
44 |
my $testbiblio = $testorder->{'biblionumber'}; |
44 |
my $testbiblio = $testorder->{'biblionumber'}; |
45 |
my @listorders = GetOrdersByBiblionumber($testbiblio); |
45 |
my @listorders = GetOrdersByBiblionumber($testbiblio); |
46 |
isa_ok( ref @listorders, 'ARRAY','GetOrdersByBiblionumber : result is an array' ); |
46 |
ok( $#listorders > 1,'GetOrdersByBiblionumber : result is not empty' ); |
47 |
ok( scalar (@listorders) >0,'GetOrdersByBiblionumber : result contains at least one element' ); |
47 |
ok( scalar (@listorders) >0,'GetOrdersByBiblionumber : result contains at least one element' ); |
48 |
my @matched_biblios = grep {$_->{biblionumber} == $testbiblio} @listorders; |
48 |
my @matched_biblios = grep {$_->{biblionumber} == $testbiblio} @listorders; |
49 |
ok ( @matched_biblios == @listorders, "all orders match"); |
49 |
ok ( @matched_biblios == @listorders, "all orders match"); |
50 |
- |
|
|