Bug 20557: Prevent Koha/Acquisition/Order.t to fail randomly

https://jenkins.koha-community.org/job/Koha_Master_D8/427/consoleFull

t/db_dependent/Koha/Acquisition/Order.t .. 1/2         # No tests run!

    #   Failed test 'No tests run for subtest "entrydate"'
    #   at t/db_dependent/Koha/Acquisition/Order.t line 97.
    # Looks like you failed 1 test of 1.

 #   Failed test 'store'
 #   at t/db_dependent/Koha/Acquisition/Order.t line 99.
 Cannot insert order: Mandatory parameter quantity is missing at t/db_dependent/Koha/Acquisition/Order.t line 77.
 # Looks like your test exited with 255 just after 2.

It happens when basket.is_standing is 0

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Jonathan Druart 2018-04-10 13:08:43 -03:00
parent b00d4d9e46
commit 33618eaec3

View file

@ -77,6 +77,7 @@ subtest 'store' => sub {
basketno => $o->basketno,
biblionumber => $o->biblionumber,
budget_id => $o->budget_id,
quantity => 1,
}
)->store;
$order->discard_changes;
@ -88,6 +89,7 @@ subtest 'store' => sub {
basketno => $o->basketno,
biblionumber => $o->biblionumber,
budget_id => $o->budget_id,
quantity => 1,
}
)->store;
$order->discard_changes;