Job
Difficulty
Cancel
Spec (updated on Mon Jun 1 13:25:36 2026)
describe("acquisitions/suggestionsarchive", 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.query("INSERT INTO suggestions(suggestedby, suggesteddate, STATUS, archived, date, title, author, branchcode, itemtype, currency, price, total) VALUES (5, \"2026-03-23\", \"ASKED\", 0, \"2026-03-23 08:13:41\", \"Shaw, Hannah\", \"Tiny but mighty\", \"CPL\", \"\", \"USD\", 0, 0), (28, \"2026-04-26\", \"ASKED\", 0, \"2026-04-26 09:13:39\", \"Cats on catnip\", \"Andrew Martilla\", \"CPL\", \"BOOK\", \"USD\", 0, 0);")
cy.login();
/* No specific padding defined */
cy.set_cookie_lang(lang);
});
it("suggestionsarchive", function () {
cy.visit("/cgi-bin/koha/suggestion/suggestion.pl");
cy.waitForPageLoad();
cy.waitForTableLoad();
cy.get("tr:nth-child(1) td:nth-child(16) div a:nth-child(2)").click();
cy.get("#table_ASKED").should('be.visible').screenshot("suggestionsarchive");
});
});
});
afterEach(function () {
cy.query("DELETE FROM suggestions where title=\"Shaw, Hannah\";")
cy.query("DELETE FROM suggestions where title=\"Cats on catnip\";")
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
suggestion/suggestion.pl
Interface
staff
Element selector
#table_ASKED
Missing selector
setup
sql INSERT INTO suggestions(suggestedby, suggesteddate, STATUS, archived, date, title, author, branchcode, itemtype, currency, price, total) VALUES (5, "2026-03-23", "ASKED", 0, "2026-03-23 08:13:41", "Shaw, Hannah", "Tiny but mighty", "CPL", "", "USD", 0, 0), (28, "2026-04-26", "ASKED", 0, "2026-04-26 09:13:39", "Cats on catnip", "Andrew Martilla", "CPL", "BOOK", "USD", 0, 0);
workflow
wait_for_table_load
click tr:nth-child(1) td:nth-child(16) div a:nth-child(2)
teardown
sql DELETE FROM suggestions where title="Shaw, Hannah";
sql DELETE FROM suggestions where title="Cats on catnip";
Notes
Cancel
Additional KTD data
Cancel