Bug 18977

Summary: Rollback branch in t/db_dependent/SIP/Message.t
Product: Koha Reporter: Lari Taskula <lari.taskula>
Component: Test SuiteAssignee: Lari Taskula <lari.taskula>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: fridolin.somers, jonathan.druart, katrin.fischer
Version: unspecified   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 18977: Rollback branch in t/db_dependent/SIP/Message.t
Bug 18977: Rollback branch in t/db_dependent/SIP/Message.t

Description Lari Taskula 2017-07-24 15:29:51 UTC
Test t/db_dependent/SIP/Message.t generates a Branch via TestBuilder outside $schema->storage->txn_begin and it stays in database when test is over. Move generation inside transaction so that it gets rolled back.
Comment 1 Lari Taskula 2017-07-24 15:32:21 UTC
Created attachment 65198 [details] [review]
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
Comment 2 Jonathan Druart 2017-07-26 17:37:28 UTC
Created attachment 65283 [details] [review]
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>
Comment 3 Jonathan Druart 2017-07-26 17:38:56 UTC
Skipping QA, it will fixes selenium tests.
Comment 4 Jonathan Druart 2017-07-26 17:39:56 UTC
Pushed to master for 17.11, thanks Lari!
Comment 5 Fridolin Somers 2017-07-31 07:31:26 UTC
Pushed to 17.05.x, will be in 17.05.03.

In order to correct selenium test failures.
Comment 6 Katrin Fischer 2017-08-01 05:41:12 UTC
This patch has been pushed to 16.11.x and will be in 16.11.11.