Bugzilla – Attachment 42658 Details for
Bug 14733
Prevent a record from having holds with duplicate priorities
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14733 - Unit Tests
Bug-14733---Unit-Tests.patch (text/plain), 1.76 KB, created by
Nicole C. Engard
on 2015-09-17 12:55:37 UTC
(
hide
)
Description:
Bug 14733 - Unit Tests
Filename:
MIME Type:
Creator:
Nicole C. Engard
Created:
2015-09-17 12:55:37 UTC
Size:
1.76 KB
patch
obsolete
>From 4c80d9003a1d0f57d40d5fd8bb9a825fa89d530a Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Wed, 26 Aug 2015 11:42:14 -0400 >Subject: [PATCH] Bug 14733 - Unit Tests > >Signed-off-by: Heather Braum <hbraum@nekls.org> >--- > t/db_dependent/Holds.t | 10 +++++++--- > 1 file changed, 7 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Holds.t b/t/db_dependent/Holds.t >index 82d6f62..3d2d7d8 100755 >--- a/t/db_dependent/Holds.t >+++ b/t/db_dependent/Holds.t >@@ -6,7 +6,7 @@ use t::lib::Mocks; > use C4::Context; > use C4::Branch; > >-use Test::More tests => 51; >+use Test::More tests => 56; > use MARC::Record; > use C4::Biblio; > use C4::Items; >@@ -70,7 +70,7 @@ foreach my $borrowernumber ( @borrowernumbers ) { > $borrowernumber, > $biblionumber, > my $bibitems = q{}, >- my $priority, >+ my $priority = 1, > my $resdate, > my $expdate, > my $notes = q{}, >@@ -80,10 +80,14 @@ foreach my $borrowernumber ( @borrowernumbers ) { > ); > } > >- > my $reserves = GetReservesFromBiblionumber({ biblionumber => $biblionumber }); > is( scalar(@$reserves), $borrowers_count, "Test GetReserves()" ); > >+is( $reserves->[0]->{priority}, 1, "Reserve 1 has a priority of 1" ); >+is( $reserves->[1]->{priority}, 2, "Reserve 2 has a priority of 2" ); >+is( $reserves->[2]->{priority}, 3, "Reserve 3 has a priority of 3" ); >+is( $reserves->[3]->{priority}, 4, "Reserve 4 has a priority of 4" ); >+is( $reserves->[4]->{priority}, 5, "Reserve 5 has a priority of 5" ); > > my ( $reservedate, $borrowernumber, $branchcode, $reserve_id ) = GetReservesFromItemnumber($itemnumber); > is( $reservedate, output_pref({ dt => dt_from_string, dateformat => 'iso', dateonly => 1 }), "GetReservesFromItemnumber should return a valid reserve date"); >-- >1.7.10.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 14733
:
41996
|
41997
|
41998
|
42658
|
42659
|
42734
|
42735
|
42736
|
42880