From b62a9f8a8229f8b7d9d5026f408ad1a8bad8ff6e Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 25 Nov 2019 11:53:00 +0100 Subject: [PATCH] Bug 23927: Add tests --- t/db_dependent/Koha/Acquisition/Order.t | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/t/db_dependent/Koha/Acquisition/Order.t b/t/db_dependent/Koha/Acquisition/Order.t index a13f9c5edc..3b7b68a533 100644 --- a/t/db_dependent/Koha/Acquisition/Order.t +++ b/t/db_dependent/Koha/Acquisition/Order.t @@ -174,7 +174,7 @@ subtest 'subscription' => sub { }; subtest 'duplicate_to | add_item' => sub { - plan tests => 2; + plan tests => 3; $schema->storage->txn_begin; @@ -241,5 +241,12 @@ subtest 'duplicate_to | add_item' => sub { ); }; + subtest 'Regression tests' => sub { + plan tests => 1; + + my $duplicated_order = $order_no_sub->duplicate_to($basket_to); + is($duplicated_order->invoiceid, undef, "invoiceid should be set to null for a new duplicated order"); + }; + $schema->storage->txn_rollback; }; -- 2.11.0