|
Lines 19-25
Link Here
|
| 19 |
|
19 |
|
| 20 |
use Modern::Perl; |
20 |
use Modern::Perl; |
| 21 |
|
21 |
|
| 22 |
use Test::More tests => 2; |
22 |
use Test::More tests => 3; |
| 23 |
|
23 |
|
| 24 |
use t::lib::TestBuilder; |
24 |
use t::lib::TestBuilder; |
| 25 |
use t::lib::Mocks; |
25 |
use t::lib::Mocks; |
|
Lines 97-99
subtest 'store' => sub {
Link Here
|
| 97 |
}; |
97 |
}; |
| 98 |
$schema->storage->txn_rollback; |
98 |
$schema->storage->txn_rollback; |
| 99 |
}; |
99 |
}; |
| 100 |
- |
100 |
|
|
|
101 |
subtest 'fund' => sub { |
| 102 |
plan tests => 1; |
| 103 |
|
| 104 |
$schema->storage->txn_begin; |
| 105 |
my $o = $builder->build_object( |
| 106 |
{ |
| 107 |
class => 'Koha::Acquisition::Orders', |
| 108 |
} |
| 109 |
); |
| 110 |
|
| 111 |
my $order = Koha::Acquisition::Orders->find( $o->ordernumber ); |
| 112 |
is( ref( $order->fund ), |
| 113 |
'Koha::Acquisition::Fund', |
| 114 |
'->fund should return a Koha::Acquisition::Fund object' ); |
| 115 |
$schema->storage->txn_rollback; |
| 116 |
}; |