Bug 17664: Silence non-zebra warnings in t/db_dependent/Search.t
[koha.git] / t / db_dependent / Serials_2.t
index 0775dae..b326ae6 100644 (file)
@@ -27,6 +27,7 @@ my $library1 = $builder->build({
 my $library2 = $builder->build({
     source => 'Branch',
 });
+my $patron_category = $builder->build({ source => 'Category' });
 my $dbh = C4::Context->dbh;
 $dbh->{RaiseError} = 1;
 
@@ -81,7 +82,7 @@ my $userid = 'my_userid';
 my $borrowernumber = C4::Members::AddMember(
     firstname =>  'my fistname',
     surname => 'my surname',
-    categorycode => 'S',
+    categorycode => $patron_category->{categorycode},
     branchcode => $my_branch,
     userid => $userid,
 );
@@ -254,7 +255,6 @@ is( GetPreviousSerialid( $subscriptionid_from_my_branch, 2 ), $serialid1, "get p
 is( GetPreviousSerialid( $subscriptionid_from_my_branch, 3 ), undef, "get previous serialid with 3, does not exist" );
 
 $schema->storage->txn_rollback;
-$dbh->rollback;
 
 # C4::Context->userenv
 sub Mock_userenv {