Lines 50-57
$module->mock('userenv', sub {
Link Here
|
50 |
my $dbh = C4::Context->dbh; |
50 |
my $dbh = C4::Context->dbh; |
51 |
|
51 |
|
52 |
# Start transaction |
52 |
# Start transaction |
53 |
$dbh->{AutoCommit} = 0; |
53 |
my $database = Koha::Database->new(); |
54 |
$dbh->{RaiseError} = 1; |
54 |
my $schema = $database->schema(); |
|
|
55 |
$schema->storage->txn_begin(); |
55 |
|
56 |
|
56 |
# Somewhat arbitrary field chosen for age restriction unit tests. Must be added to db before the framework is cached |
57 |
# Somewhat arbitrary field chosen for age restriction unit tests. Must be added to db before the framework is cached |
57 |
$dbh->do("update marc_subfield_structure set kohafield='biblioitems.agerestriction' where tagfield='521' and tagsubfield='a'"); |
58 |
$dbh->do("update marc_subfield_structure set kohafield='biblioitems.agerestriction' where tagfield='521' and tagsubfield='a'"); |
Lines 678-684
is( $status, 'Reserved', 'MoveReserve did not fill future hold of 3 days');
Link Here
|
678 |
$dbh->do('DELETE FROM reserves', undef, ($bibnum)); |
679 |
$dbh->do('DELETE FROM reserves', undef, ($bibnum)); |
679 |
|
680 |
|
680 |
# we reached the finish |
681 |
# we reached the finish |
681 |
$dbh->rollback; |
682 |
$schema->storage->txn_rollback(); |
682 |
|
683 |
|
683 |
sub count_hold_print_messages { |
684 |
sub count_hold_print_messages { |
684 |
my $message_count = $dbh->selectall_arrayref(q{ |
685 |
my $message_count = $dbh->selectall_arrayref(q{ |
685 |
- |
|
|