Bugzilla – Attachment 117601 Details for
Bug 24446
Stockrotation: Update to use daterequested in branchtransfers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24446: (QA follow-up) Update transferbook Test
Bug-24446-QA-follow-up-Update-transferbook-Test.patch (text/plain), 5.40 KB, created by
Jonathan Druart
on 2021-03-03 14:32:28 UTC
(
hide
)
Description:
Bug 24446: (QA follow-up) Update transferbook Test
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-03-03 14:32:28 UTC
Size:
5.40 KB
patch
obsolete
>From 962a8c428d2747de89bb4fc85a14549d06f42d73 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Thu, 21 Jan 2021 14:43:26 +0000 >Subject: [PATCH] Bug 24446: (QA follow-up) Update transferbook Test >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >Needed for a rebase, a new test was introduced so we need to add the >trigger option into that test now too. > >Signed-off-by: Kathleen Milne <kathleen.milne@cne-siar.gov.uk> >Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi> >--- > t/db_dependent/Circulation/transferbook.t | 27 ++++++++++++++++------- > 1 file changed, 19 insertions(+), 8 deletions(-) > >diff --git a/t/db_dependent/Circulation/transferbook.t b/t/db_dependent/Circulation/transferbook.t >index 54d4b65819..03c735afbd 100755 >--- a/t/db_dependent/Circulation/transferbook.t >+++ b/t/db_dependent/Circulation/transferbook.t >@@ -38,11 +38,13 @@ subtest 'transfer a non-existant item' => sub { > my $badbc = $item->barcode; > $item->delete; > >+ my $trigger = "Manual"; > my ( $dotransfer, $messages ) = > C4::Circulation::transferbook({ > from_branch => $item->homebranch, > to_branch => $library->{branchcode}, >- barcode => $badbc >+ barcode => $badbc, >+ trigger => $trigger > }); > is( $dotransfer, 0, "Can't transfer a bad barcode" ); > is_deeply( >@@ -120,7 +122,8 @@ subtest 'transfer already at destination' => sub { > my ($dotransfer, $messages ) = transferbook({ > from_branch => $item->homebranch, > to_branch => $library->branchcode, >- barcode => $item->barcode >+ barcode => $item->barcode, >+ trigger => "Manual" > }); > is( $dotransfer, 0, 'Transfer of item failed when destination equals holding branch' ); > is_deeply( >@@ -142,7 +145,8 @@ subtest 'transfer already at destination' => sub { > ($dotransfer, $messages ) = transferbook({ > from_branch => $item->homebranch, > to_branch => $library->branchcode, >- barcode => $item->barcode >+ barcode => $item->barcode, >+ trigger => "Manual" > }); > is( $dotransfer, 1, 'Transfer of reserved item succeeded without ignore reserves' ); > is( $messages->{ResFound}->{ResFound}, 'Reserved', "We found the reserve"); >@@ -177,7 +181,8 @@ subtest 'transfer an issued item' => sub { > my ($dotransfer, $messages) = transferbook({ > from_branch => $item->homebranch, > to_branch => $library->branchcode, >- barcode => $item->barcode >+ barcode => $item->barcode, >+ trigger => "Manual" > }); > is( $messages->{WasReturned}, $patron->borrowernumber, 'transferbook should have return a WasReturned flag is the item was issued before the transferbook call'); > >@@ -197,7 +202,8 @@ subtest 'transfer an issued item' => sub { > ($dotransfer, $messages ) = transferbook({ > from_branch => $item->homebranch, > to_branch => $library->branchcode, >- barcode => $item->barcode >+ barcode => $item->barcode, >+ trigger => "Manual" > }); > is( $dotransfer, 1, 'Transfer of reserved item succeeded without ignore reserves' ); > is( $messages->{ResFound}->{ResFound}, 'Reserved', "We found the reserve"); >@@ -236,7 +242,8 @@ subtest 'ignore_reserves flag' => sub { > my ($dotransfer, $messages ) = transferbook({ > from_branch => $item->homebranch, > to_branch => $library->branchcode, >- barcode => $item->barcode >+ barcode => $item->barcode, >+ trigger => "Manual" > }); > is( $dotransfer, 1, 'Transfer of reserved item succeeded without ignore reserves' ); > is( $messages->{ResFound}->{ResFound}, 'Reserved', "We found the reserve"); >@@ -247,7 +254,8 @@ subtest 'ignore_reserves flag' => sub { > from_branch => $item->homebranch, > to_branch => $library->branchcode, > barcode => $item->barcode, >- ignore_reserves => $ignore_reserves >+ ignore_reserves => $ignore_reserves, >+ trigger => "Manual" > }); > is( $dotransfer, 1, 'Transfer of reserved item succeeded with ignore reserves: false' ); > is( $messages->{ResFound}->{ResFound}, 'Reserved', "We found the reserve"); >@@ -258,7 +266,8 @@ subtest 'ignore_reserves flag' => sub { > from_branch => $item->homebranch, > to_branch => $library->branchcode, > barcode => $item->barcode, >- ignore_reserves => $ignore_reserves >+ ignore_reserves => $ignore_reserves, >+ trigger => "Manual" > }); > is( $dotransfer, 0, 'Transfer of reserved item failed with ignore reserves: true' ); > is_deeply( >@@ -280,6 +289,7 @@ subtest 'transferbook test from branch' => sub { > from_branch => $library->branchcode, > to_branch => $item->homebranch, > barcode => $item->barcode, >+ trigger => "Manual" > }); > my ($datesent,$from_branch,$to_branch) = GetTransfers($item->itemnumber); > is( $from_branch, $library->branchcode, 'The transfer is initiated from the specified branch, not the items home or holdingbranch'); >@@ -288,6 +298,7 @@ subtest 'transferbook test from branch' => sub { > from_branch => $item->homebranch, > to_branch => $library->branchcode, > barcode => $item->barcode, >+ trigger => "Manual" > }); > ($datesent,$from_branch,$to_branch) = GetTransfers($item->itemnumber); > is( $from_branch, $item->homebranch, 'The transfer is initiated from the specified branch'); >-- >2.20.1
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 24446
:
105943
|
105944
|
105945
|
107246
|
107247
|
107248
|
107249
|
107250
|
107252
|
107253
|
107254
|
107255
|
107256
|
107301
|
107302
|
107303
|
107304
|
107305
|
110280
|
110281
|
110282
|
110283
|
110533
|
110534
|
110535
|
110536
|
110537
|
110538
|
110539
|
110540
|
110541
|
110542
|
111322
|
116557
|
116558
|
116559
|
116560
|
116561
|
116562
|
116563
|
116564
|
116565
|
116566
|
116567
|
116568
|
116569
|
116570
|
117589
|
117590
|
117591
|
117592
|
117593
|
117594
|
117595
|
117596
|
117597
|
117598
|
117599
|
117600
| 117601 |
117602
|
117603
|
117604
|
117605
|
117606
|
117607
|
120116