See comment18 of bug 32242
Created attachment 144108 [details] [review] Bug 32304: BackgroundJobs.t - Start purge test with clean sheet Test plan: Run t/db_dependent/Koha/BackgroundJobs.t Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Trivial: self SO
It's usually a bad idea to remove data. You should adapt your code, like count before and after. We had problem recently (like delete from borrowers does not work if you have issues, etc.)
(In reply to Jonathan Druart from comment #3) > It's usually a bad idea to remove data. You should adapt your code, like > count before and after. We had problem recently (like delete from borrowers > does not work if you have issues, etc.) Thanks. I didnt write this test. So I leave that to the author. Just providing a quick fix for a 'silly' assumption. Note that there are a lot of those deletes in test scripts though.
31969 is all wrong, see bug 31969 comment 18
Tomás: What is your plan here?
Created attachment 144227 [details] [review] Bug 32304: Fix subtest search_limited Jenkins reported: not ok 1 - No jobs found without userenv We need to check if there are jobs without borrowernumber. Test plan: Run test again. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Created attachment 144228 [details] [review] Bug 32304: BackgroundJobs.t: Fix subtest purge Instead of deleting, I added a count :) Note that one of the purges eventually deletes my older jobs.. Test plan: Run t/db_dependent/Koha/BackgroundJobs.t Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment on attachment 144108 [details] [review] Bug 32304: BackgroundJobs.t - Start purge test with clean sheet To make Joubu happy ;)
Created attachment 144231 [details] [review] Bug 32304: Fix subtest search_limited Jenkins reported: not ok 1 - No jobs found without userenv We need to check if there are jobs without borrowernumber. Test plan: Run test again. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 144232 [details] [review] Bug 32304: BackgroundJobs.t: Fix subtest purge Instead of deleting, I added a count :) Note that one of the purges eventually deletes my older jobs.. Test plan: Run t/db_dependent/Koha/BackgroundJobs.t Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Confirmed fixes the failures, thanks Marcel. Straight PQA from me.
Please see last patch on bug 31969.
Pushed to master for 22.11. Nice work everyone, thanks!
No idea why this has been pushed right before the follow-up on bug 31969 (Use filter_by_last_update) that actually... removes this code.