Bug 18601: OAI/Sets.t mangles data due to truncate in ModOAISetsBiblios
authorMarcel de Rooy <m.de.rooy@rijksmuseum.nl>
Mon, 15 May 2017 07:58:04 +0000 (09:58 +0200)
committerKatrin Fischer <katrin.fischer.83@web.de>
Thu, 15 Jun 2017 20:21:38 +0000 (22:21 +0200)
commit9eace51161fb8af946468d293befee9c5847c872
tree2e9800b4ca0de98c82f0ec0f402309866cf02976
parentd50b5a6c3981ad6a3eee74bd3c8a3da171f9208e
Bug 18601: OAI/Sets.t mangles data due to truncate in ModOAISetsBiblios

This patch replaces the TRUNCATE statement in ModOAISetsBiblios by a
DELETE statement. A truncate will cause an implicit commit and will
therefore commit the transaction started in the test script.

Also simplifying the module load in the test script.

Test plan:
Do not apply this patch and observe that biblio records are added to your
database by running t/db_dependent/OAI/Sets.t.
Apply this patch, run the test again and verify that it does no longer
add records to your biblio table.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e0444e8600efbe06016ff857f23ea85893a93041)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 28928c69376fd25edaee8a7843dc4fd4309f0615)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
C4/OAI/Sets.pm
t/db_dependent/OAI/Sets.t