http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10528
kenza <kenza.z...@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #19713|0 |1 is obsolete| | --- Comment #7 from kenza <kenza.z...@biblibre.com> --- Created attachment 19756 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=19756&action=edit Bug 10528: C4::Booksellers needs unit tests Unit tests are wrap in a database transaction. GetBooksellerWithLateOrders has been modify in order to pass the tests. Now it considers the field $estimateddeliverydateto and it replaces it by now() only if it is undef. More it doesn't test if $aqbookseller.deliverytime is not Null anymore but if $deliverytime = null or undef, it replaces it by 0. It also verifies if $delay is >= 0. ModBookseller has been modify in order to be more explicit: before it always returned undef. Now it returns : 1 -> If a modification has been done 0E0 -> If the given id doesn't exist undef -> If no id given DelBookSeller has been modify in order to be more explicit: Before it returned undef, now it returns $sth->execute($id), so we can verify how many bookSellers have been deleted. Test Plan : prove t/db_dependant/Booksellers.t t/db_dependent/Bookseller.t .. 2/67 [Some warnings about uninitialized values] WARNING: GetBooksellerWithLateOrders is called with a negative value at /home/kenza/workspace/kohaclone/C4/Bookseller.pm line 137. t/db_dependent/Bookseller.t .. ok All tests successful. Files=1, Tests=67, 1 wallclock secs ( 0.03 usr 0.00 sys + 0.43 cusr 0.03 csys = 0.49 CPU) Result: PASS -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/