Job
Difficulty
Hard
Cancel
Spec (updated on Thu Jun 4 10:22:47 2026)
describe("circ/warnings/prevcheckout", function () {
const languages = ['en', 'es-ES', 'fr-FR', 'de-DE', 'el-GR', 'hi', 'zh-Hant-TW'];
languages.forEach((lang) => {
describe(`in ${lang}`, () => {
beforeEach(function(){
// Skip if 'en' test failed
if (Cypress.env("EN_TEST_FAILED")) {
this.skip();
}
cy.set_syspref("CheckPrevCheckout", "hardyes");
cy.set_syspref("CheckPrevCheckoutDelay", "1");
cy.login();
/* No specific padding defined */
cy.set_cookie_lang(lang);
});
it("prevcheckout", function () {
cy.visit("/cgi-bin/koha/circ/circulation.pl?borrowernumber=19");
cy.waitForPageLoad();
cy.get("#barcode").type("39999000006018");
cy.get("button.btn:nth-child(4)").click();
cy.wait_for_ajax();
cy.visit("/cgi-bin/koha/circ/returns.pl");
cy.waitForPageLoad();
cy.get("#barcode").type("39999000006018");
cy.get("button.btn:nth-child(4)").click();
cy.wait_for_ajax();
cy.visit("/cgi-bin/koha/circ/circulation.pl?borrowernumber=19");
cy.waitForPageLoad();
cy.get("#barcode").type("39999000006018");
cy.get("button.btn:nth-child(4)").click();
cy.wait_for_ajax();
cy.get("#circ_needsconfirmation").should('be.visible').screenshot("prevcheckout");
});
});
});
afterEach(function () {
cy.set_syspref("CheckPrevCheckout", "hardno");
cy.set_syspref("CheckPrevCheckoutDelay", "0");
Cypress.env('PADDING_BEFORE_SCREENSHOT', undefined);
// Set EN_TEST_FAILED if the 'en' test failed
if (this.currentTest.parent.title.includes('in en') && this.currentTest.state === 'failed') {
Cypress.env("EN_TEST_FAILED", true);
}
});
});
Spec data
Page
circ/circulation.pl?borrowernumber=19
Interface
staff
Element selector
#circ_needsconfirmation
Missing selector
Y
setup
set_syspref CheckPrevCheckout=hardyes
set_syspref CheckPrevCheckoutDelay=1
workflow
type #barcode=39999000006018
click button.btn:nth-child(4)
wait_for_ajax
go_to /circ/returns.pl
type #barcode=39999000006018
click button.btn:nth-child(4)
wait_for_ajax
go_to /circ/circulation.pl?borrowernumber=19
type #barcode=39999000006018
click button.btn:nth-child(4)
wait_for_ajax
teardown
set_syspref CheckPrevCheckout=hardno
set_syspref CheckPrevCheckoutDelay=0
Notes
[Fixed] 2026-06-02 blocked because go_to doesn't work properly (see issue https://gitlab.com/joubu/koha-manual-screenshots-wip/-/work_items/35 )
Cancel
Additional KTD data
Cancel