fix tests for vouchers (#2012)
This commit is contained in:
parent
eabc944604
commit
bd15c52ee5
2 changed files with 3 additions and 3 deletions
|
@ -133,6 +133,7 @@ Cypress.Commands.add(
|
||||||
|
|
||||||
Cypress.Commands.add("softExpectSkeletonIsVisible", () => {
|
Cypress.Commands.add("softExpectSkeletonIsVisible", () => {
|
||||||
cy.get(SHARED_ELEMENTS.circularProgress).should("not.exist");
|
cy.get(SHARED_ELEMENTS.circularProgress).should("not.exist");
|
||||||
|
cy.get(SHARED_ELEMENTS.progressBar).should("be.visible");
|
||||||
cy.get("body").then($body => {
|
cy.get("body").then($body => {
|
||||||
if ($body.find(SHARED_ELEMENTS.skeleton).length) {
|
if ($body.find(SHARED_ELEMENTS.skeleton).length) {
|
||||||
cy.softAssertVisibility(SHARED_ELEMENTS.skeleton);
|
cy.softAssertVisibility(SHARED_ELEMENTS.skeleton);
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import { VOUCHERS_SELECTORS } from "../../../elements/discounts/vouchers";
|
import { VOUCHERS_SELECTORS } from "../../../elements/discounts/vouchers";
|
||||||
import { BUTTON_SELECTORS } from "../../../elements/shared/button-selectors";
|
import { BUTTON_SELECTORS } from "../../../elements/shared/button-selectors";
|
||||||
import { voucherDetailsUrl } from "../../../fixtures/urlList";
|
import { urlList, voucherDetailsUrl } from "../../../fixtures/urlList";
|
||||||
import { urlList } from "../../../fixtures/urlList";
|
|
||||||
import { ONE_PERMISSION_USERS } from "../../../fixtures/users";
|
import { ONE_PERMISSION_USERS } from "../../../fixtures/users";
|
||||||
import { createCheckoutWithVoucher } from "../../api/utils/ordersUtils";
|
import { createCheckoutWithVoucher } from "../../api/utils/ordersUtils";
|
||||||
import { selectChannelInDetailsPages } from "../channelsPage";
|
import { selectChannelInDetailsPages } from "../channelsPage";
|
||||||
|
@ -57,7 +56,7 @@ export function createVoucher({
|
||||||
}
|
}
|
||||||
cy.get(BUTTON_SELECTORS.confirm)
|
cy.get(BUTTON_SELECTORS.confirm)
|
||||||
.click()
|
.click()
|
||||||
.confirmationMessageShouldDisappear();
|
.confirmationMessageShouldAppear();
|
||||||
}
|
}
|
||||||
|
|
||||||
export function setVoucherDate({
|
export function setVoucherDate({
|
||||||
|
|
Loading…
Reference in a new issue