https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15504
--- Comment #40 from Matt Blenkinsop <[email protected]> --- Notes on testing - The intent of track_login_daily is to log a patron action/activity once per day and cache this activity. This means that the lastseen field is only updated once per day rather than every time an action is performed. This makes sense in operation but makes testing this patch more complicated. We want to test multiple methods of updating the lastseen field. If we don’t clear that cache before each method then the patch will work as intended but the test plan will fail as only one update will be performed. The test plan therefore includes a “restart_all” step at various points before an activity is performed - this step uses “restart_all” in KTD to clear the cache and must not be skipped otherwise the test plan will fail. Furthermore, the “Login to OPAC” action, called in checkauth is triggered very often throughout Koha through various route guards etc. The test plan begins by testing this activity first and then de-selecting this option. If this option is left selected, then it will trigger before the other actions (check in, check out etc) can be triggered and the test plan will fail due to the login action already being cached again. Test plan: 1. Apply patch 2. reset_all 3. Navigate to Administration and search for “TrackLastPatronActivity” 4. Observe that there are two system preferences - “TrackLastPatronActivity” and “TrackLastPatronActivityTriggers” 5. Change TrackLastPatronActivity to “Do” and save 6. Choose a patron to use as a test subject 7. In the database, observe that the “lastseen” property for that patron is still NULL 8. In TrackLastPatronActivityTriggers, select “Login to OPAC” and save 9. In the OPAC, log in as your selected patron 10. In the database, observe that the “lastseen” property for that patron has been updated 11. In TrackLastPatronActivityTriggers, unselect “Login to OPAC” and instead select “Checking out an item” and save 12. restart_all 13. Check out an item to your selected patron 14. In the database, observe that the “lastseen” property for that patron has been updated 15. In TrackLastPatronActivityTriggers, select “Renewing an item” and save 16. restart_all 17. In either the OPAC or the staff client - renew the item that you have just checked out to that patron 18. In the database, observe that the “lastseen” property for that patron has been updated 19. In TrackLastPatronActivityTriggers, select “Returning an item” and save 20. restart_all 21. Return the item that you have checked out to the patron 22. In the database, observe that the “lastseen” property for that patron has been updated 23. In TrackLastPatronActivityTriggers, select “Connection to Koha via SIP or ILSDI” and save 24. In system preferences, search for “ILS-DI” and enable this preference 25. restart_all 26. In the browser, navigate to http://DOMAIN/cgi-bin/koha/ilsdi.pl?service=AuthenticatePatron&username=USERNAME&password=PASSWORD, swapping out DOMAIN, USERNAME and PASSWORD to match your koha instance and patron details 27. In the database, observe that the “lastseen” property for that patron has been updated 28. Run “prove -v t/db_dependent/Auth.t” 29. Observe that all tests pass 30. Sign off! -- You are receiving this mail because: You are the assignee for the bug. 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/
