Update user-preferences-profile.spec.ts

This commit is contained in:
Jamie 2023-06-20 12:22:03 +01:00 committed by GitHub
parent 4dd78e388f
commit 4a5b7c8dc6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -12,13 +12,13 @@ const langs = [
]; ];
langs.forEach((l) => { langs.forEach((l) => {
it.only(`Change language to ${l.code}, UI should update`, () => { it(`Change language to ${l.code}, UI should update`, () => {
cy.intercept('POST','**/language').as('langSave'); cy.intercept('POST','**/language').as('langSave');
Page.visit(); Page.visit();
Page.profile.languageSelectBox.click(); Page.profile.languageSelectBox.click();
Page.profile.languageSelectBoxOption(l.code).click(); Page.profile.languageSelectBoxOption(l.code).click();
cy.wait(1000); // wait for UI to update cy.wait(2000); // wait for UI to update
Page.navbar.discover.contains(l.discover); Page.navbar.discover.contains(l.discover);
cy.wait('@langSave').then((intercept) => { cy.wait('@langSave').then((intercept) => {