Bugzilla – Attachment 66042 Details for
Bug 19024
Order cancelled status is reset on basket close
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED OFF] Bug 19024: Add tests
SIGNED-OFF-Bug-19024-Add-tests.patch (text/plain), 1.88 KB, created by
Katrin Fischer
on 2017-08-15 19:00:33 UTC
(
hide
)
Description:
[SIGNED OFF] Bug 19024: Add tests
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2017-08-15 19:00:33 UTC
Size:
1.88 KB
patch
obsolete
>From 7ddf865118c7b2ed16bff6d1c82e54af8353525b Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 9 Aug 2017 16:09:32 -0300 >Subject: [PATCH] [SIGNED OFF] Bug 19024: Add tests > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > t/db_dependent/Acquisition/close_reopen_basket.t | 11 ++++++++++- > 1 file changed, 10 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/Acquisition/close_reopen_basket.t b/t/db_dependent/Acquisition/close_reopen_basket.t >index aba4824..750f1c5 100644 >--- a/t/db_dependent/Acquisition/close_reopen_basket.t >+++ b/t/db_dependent/Acquisition/close_reopen_basket.t >@@ -2,7 +2,7 @@ > > use Modern::Perl; > >-use Test::More tests => 6; >+use Test::More tests => 10; > use C4::Acquisition; > use C4::Biblio qw( AddBiblio DelBiblio ); > use C4::Budgets; >@@ -82,4 +82,13 @@ C4::Acquisition::ReopenBasket( $basketno ); > is ( scalar( map { $_->{orderstatus} eq 'ordered' ? 1 : () } @orders ), 0, "No order are ordered, the basket is reopen" ); > is ( scalar( map { $_->{orderstatus} eq 'new' ? 1 : () } @orders ), 2, "2 orders are new, the basket is reopen" ); > >+C4::Acquisition::DelOrder( $biblionumber1, $ordernumber1 ); >+my ( $order ) = C4::Acquisition::GetOrders( $basketno, {cancelled => 1} ); >+is( $order->{ordernumber}, $ordernumber1, 'The order returned by GetOrders should have been the right one' ); >+is( $order->{orderstatus}, 'cancelled', 'DelOrder should have set status to cancelled' ); >+C4::Acquisition::CloseBasket( $basketno ); >+( $order ) = C4::Acquisition::GetOrders( $basketno, {cancelled => 1} ); >+is( $order->{ordernumber}, $ordernumber1, 'The order returned by GetOrders should have been the right one' ); >+is( $order->{orderstatus}, 'cancelled', 'CloseBasket should not reset the status to ordered for cancelled orders' ); >+ > $schema->storage->txn_rollback(); >-- >2.7.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 19024
:
65434
|
65439
|
65776
|
66004
|
66005
|
66039
|
66040
|
66041
|
66042
|
66043
|
66044
|
66725
|
66726
|
66727