View | Details | Raw Unified | Return to bug 41214
Collapse All | Expand All

(-)a/t/cypress/integration/SIP2/Accounts.ts (-1 / +11 lines)
Lines 77-82 describe("Accounts", () => { Link Here
77
    beforeEach(() => {
77
    beforeEach(() => {
78
        cy.login();
78
        cy.login();
79
        cy.title().should("eq", "Koha staff interface");
79
        cy.title().should("eq", "Koha staff interface");
80
        cy.set_syspref("UseCashRegisters", 0);
80
    });
81
    });
81
82
82
    it("List accounts", () => {
83
    it("List accounts", () => {
Lines 232-237 describe("Accounts", () => { Link Here
232
233
233
        cy.get("#login_id").should("not.be.visible");
234
        cy.get("#login_id").should("not.be.visible");
234
235
236
        cy.get("#register_id").should("not.exist");
237
235
        // Submit the form, get 500
238
        // Submit the form, get 500
236
        cy.intercept("POST", "/api/v1/sip2/accounts", {
239
        cy.intercept("POST", "/api/v1/sip2/accounts", {
237
            statusCode: 500,
240
            statusCode: 500,
Lines 253-258 describe("Accounts", () => { Link Here
253
        );
256
        );
254
    });
257
    });
255
258
259
    it("Should show/hide register_id based on syspref", () => {
260
        cy.set_syspref("UseCashRegisters", 1).then(() => {
261
            cy.visit("/cgi-bin/koha/sip2/accounts/add");
262
            cy.get("#register_id").should("exist");
263
        });
264
    });
265
256
    it("Edit account", () => {
266
    it("Edit account", () => {
257
        let account = get_account();
267
        let account = get_account();
258
        let accounts = [account];
268
        let accounts = [account];
Lines 282-287 describe("Accounts", () => { Link Here
282
292
283
        // Form has been correctly filled in
293
        // Form has been correctly filled in
284
        cy.get("#login_id").should("have.value", accounts[0].login_id);
294
        cy.get("#login_id").should("have.value", accounts[0].login_id);
295
        cy.get("#register_id").should("not.exist");
285
296
286
        // cy.get("#checkin_yes").should("be.checked");
297
        // cy.get("#checkin_yes").should("be.checked");
287
        // cy.get("#checkout_yes").should("be.checked");
298
        // cy.get("#checkout_yes").should("be.checked");
288
- 

Return to bug 41214