Bug 32131: Move set_ERM_sys_pref_value to before

We cannot (yet) move login to before, but we can set the pref before all
the tests. We need to login in before anyway to retrieve the value of
the pref.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Jonathan Druart 2022-11-16 08:57:40 +01:00 committed by Tomas Cohen Arazi
parent 5d794c99cc
commit fc48e6117f
No known key found for this signature in database
GPG Key ID: 0A272EA1B2F3C15F
4 changed files with 4 additions and 4 deletions

View File

@ -119,12 +119,12 @@ function get_licenses_to_relate() {
describe("Agreement CRUD operations", () => {
before(() => {
cy.fetch_initial_ERM_sys_pref_value();
cy.set_ERM_sys_pref_value(true);
});
beforeEach(() => {
cy.login("koha", "koha");
cy.title().should("eq", "Koha staff interface");
cy.set_ERM_sys_pref_value(true);
});
after(() => {

View File

@ -35,12 +35,12 @@ function get_license() {
describe("License CRUD operations", () => {
before(() => {
cy.fetch_initial_ERM_sys_pref_value();
cy.set_ERM_sys_pref_value(true);
});
beforeEach(() => {
cy.login("koha", "koha");
cy.title().should("eq", "Koha staff interface");
cy.set_ERM_sys_pref_value(true);
});
after(() => {

View File

@ -26,12 +26,12 @@ function get_package() {
describe("Package CRUD operations", () => {
before(() => {
cy.fetch_initial_ERM_sys_pref_value();
cy.set_ERM_sys_pref_value(true);
});
beforeEach(() => {
cy.login("koha", "koha");
cy.title().should("eq", "Koha staff interface");
cy.set_ERM_sys_pref_value(true);
});
after(() => {

View File

@ -69,12 +69,12 @@ function get_packages_to_relate() {
describe("Title CRUD operations", () => {
before(() => {
cy.fetch_initial_ERM_sys_pref_value();
cy.set_ERM_sys_pref_value(true);
});
beforeEach(() => {
cy.login("koha", "koha");
cy.title().should("eq", "Koha staff interface");
cy.set_ERM_sys_pref_value(true);
});
after(() => {