[Koha-bugs] [Bug 18802] Circulation.t fails if finesMode != "Do not calculate"

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Aug 4 08:28:04 CEST 2017


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18802

Marcel de Rooy <m.de.rooy at rijksmuseum.nl> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #65375|0                           |1
        is obsolete|                            |

--- Comment #8 from Marcel de Rooy <m.de.rooy at rijksmuseum.nl> ---
Created attachment 65488
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=65488&action=edit
Bug 18802: Fix Circulation.t if finesMode ne 'production'

If finesMode is not set to production, only 1 fine will be created (the renewal
one will not). This is what assumes the tests.
If set to 'production', the tests will fail because the fines will not
be deleted (because of the DBIx::Class) warning.
Now we mock the value before charging.

prove t/db_dependent/Circulation.t
t/db_dependent/Circulation.t .. 16/95
DBIx::Class::Storage::DBI::select_single(): Query returned more than one row. 
SQL that returns multiple rows is DEPRECATED for ->find and ->single at
t/db_dependent/Circulation.t line 491
t/db_dependent/Circulation.t .. 56/95
    #   Failed test 'Can auto renew, OPACFineNoRenewals=10, patron has 10'
    #   at t/db_dependent/Circulation.t line 670.
    #          got: 'auto_too_much_oweing'
    #     expected: 'auto_renew'
    # Looks like you failed 1 test of 6.

Test plan:
  prove t/db_dependent/Circulation.t
should return green whatever the value of finesMode

Signed-off-by: Marcel de Rooy <m.de.rooy at rijksmuseum.nl>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list