https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28632
David Nind <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #122447|0 |1 is obsolete| | --- Comment #2 from David Nind <[email protected]> --- Created attachment 122460 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=122460&action=edit Bug 28632: Make patrons.t robust in terms of elapsed time between tests This patch changes the tests so they don't try to compare updated_on from many tests ago, so it is less fragile. I added a warn on the unmatched fields for convenience. To test: 1. Run: $ kshell k$ prove t/db_dependent/api/v1/patrons.t => SUCCESS: Tests pass! 2. Make your computer very slow 3. Repeat 1 => FAIL: You get things like: t/db_dependent/api/v1/patrons.t .. 3/7 # Failed test 'Returned patron from update matches expected' # at t/db_dependent/api/v1/patrons.t line 513. # Structures begin differing at: # $got->{updated_on} = '2021-06-25T14:26:20+00:00' # $expected->{updated_on} = '2021-06-25T14:26:19+00:00' # Looks like you failed 1 test of 42. 4. Apply this patch 5. Repeat 1 => SUCCESS: Tests pass again! 6. Sign off :-D Signed-off-by: David Nind <[email protected]> -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://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/
