|
Lines 16-21
Link Here
|
| 16 |
# along with Koha; if not, see <http://www.gnu.org/licenses>. |
16 |
# along with Koha; if not, see <http://www.gnu.org/licenses>. |
| 17 |
|
17 |
|
| 18 |
use Modern::Perl; |
18 |
use Modern::Perl; |
|
|
19 |
use DateTime; |
| 19 |
|
20 |
|
| 20 |
use C4::Circulation; |
21 |
use C4::Circulation; |
| 21 |
use Koha::Database; |
22 |
use Koha::Database; |
|
Lines 42-47
$dbh->do('DELETE FROM issuingrules');
Link Here
|
| 42 |
$dbh->do('DELETE FROM borrowers'); |
43 |
$dbh->do('DELETE FROM borrowers'); |
| 43 |
$dbh->do('DELETE FROM items'); |
44 |
$dbh->do('DELETE FROM items'); |
| 44 |
|
45 |
|
|
|
46 |
my $now_value = DateTime->now(); |
| 47 |
my $mocked_datetime = Test::MockModule->new('DateTime'); |
| 48 |
$mocked_datetime->mock( 'now', sub { return $now_value; } ); |
| 49 |
|
| 45 |
my $library = $builder->build( { source => 'Branch' } ); |
50 |
my $library = $builder->build( { source => 'Branch' } ); |
| 46 |
my $category = $builder->build( { source => 'Category' } ); |
51 |
my $category = $builder->build( { source => 'Category' } ); |
| 47 |
my $itemtype = $builder->build( { source => 'Itemtype' } )->{itemtype}; |
52 |
my $itemtype = $builder->build( { source => 'Itemtype' } )->{itemtype}; |
| 48 |
- |
|
|