From 845d32b1f77975c0d78fbaa12f0a320da73d5f71 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 8 Jun 2017 15:36:40 -0300 Subject: [PATCH] Bug 18762: Remove a warning from History.t Test plan: prove t/db_dependent/Search/History.t should not display any warnings Signed-off-by: Lee Jamison Signed-off-by: Mark Tompsett --- t/db_dependent/Search/History.t | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/t/db_dependent/Search/History.t b/t/db_dependent/Search/History.t index 7044921a48..a10b5f8f9f 100644 --- a/t/db_dependent/Search/History.t +++ b/t/db_dependent/Search/History.t @@ -19,9 +19,10 @@ use List::Util qw( shuffle ); use C4::Context; use Koha::DateUtils; + +my $schema = Koha::Database->new->schema; +$schema->storage->txn_begin; my $dbh = C4::Context->dbh; -$dbh->{AutoCommit} = 0; -$dbh->{RaiseError} = 1; use_ok('Koha::DateUtils'); use_ok('C4::Search::History'); @@ -472,6 +473,4 @@ $result2 = $schema->resultset('SearchHistory')->search()->count; is($result2, $result+1, 'new search added to borrower'); }; -$dbh->rollback; - done_testing; -- 2.11.0