Browse Source

Bug 18977: Rollback branch in t/db_dependent/SIP/Message.t

To test:
1. Before applying patch, check the amount of branches in database
2. prove t/db_dependent/SIP/Message.t
3. See that a new branch is stored
4. Apply patch
5. prove t/db_dependent/SIP/Message.t
6. See that a new branch is no longer stored

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
17.11.x
Lari Taskula 5 years ago
committed by Jonathan Druart
parent
commit
139b66f656
  1. 6
      t/db_dependent/SIP/Message.t

6
t/db_dependent/SIP/Message.t

@ -54,15 +54,12 @@ my $mockILS = Test::MockObject->new;
$mockILS->mock( 'check_inst_id', sub {} );
$mockILS->mock( 'institution_id', sub { $branchcode; } );
$mockILS->mock( 'find_patron', sub { $findpatron; } );
$branch = $builder->build({
source => 'Branch',
});
$branchcode = $branch->{branchcode};
# START testing
subtest 'Testing Patron Status Request V2' => sub {
$schema->storage->txn_begin;
plan tests => 13;
$branchcode = $builder->build({ source => 'Branch' })->{branchcode};
$C4::SIP::Sip::protocol_version = 2;
test_request_patron_status_v2();
$schema->storage->txn_rollback;
@ -71,6 +68,7 @@ subtest 'Testing Patron Status Request V2' => sub {
subtest 'Testing Patron Info Request V2' => sub {
$schema->storage->txn_begin;
plan tests => 18;
$branchcode = $builder->build({ source => 'Branch' })->{branchcode};
$C4::SIP::Sip::protocol_version = 2;
test_request_patron_info_v2();
$schema->storage->txn_rollback;

Loading…
Cancel
Save