test fix create product without sku (#3623)

This commit is contained in:
wojteknowacki 2023-05-18 09:47:12 +02:00 committed by GitHub
parent 352ac9566b
commit 757833ca57
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View file

@ -150,13 +150,13 @@ describe("Creating variants", () => {
getProductVariants(createdProduct.id, defaultChannel.slug); getProductVariants(createdProduct.id, defaultChannel.slug);
}) })
.then(([firstVariant, secondVariant]) => { .then(([firstVariant, secondVariant]) => {
expect(firstVariant).to.have.property("price", variants[0].price); expect(secondVariant).to.have.property("price", variants[0].price);
expect(secondVariant).to.have.property("name", name); expect(firstVariant).to.have.property("name", name);
expect(secondVariant).to.have.property("price", variants[1].price); expect(firstVariant).to.have.property("price", variants[1].price);
createWaitingForCaptureOrder({ createWaitingForCaptureOrder({
channelSlug: defaultChannel.slug, channelSlug: defaultChannel.slug,
email: "example@example.com", email: "example@example.com",
variantsList: [secondVariant], variantsList: [firstVariant],
shippingMethodName: shippingMethod.name, shippingMethodName: shippingMethod.name,
address, address,
}); });

View file

@ -152,6 +152,7 @@ export function addVariantToDataGrid(variantName) {
export function enterVariantEditPage() { export function enterVariantEditPage() {
cy.get(PRODUCT_DETAILS.dataGridTable) cy.get(PRODUCT_DETAILS.dataGridTable)
.scrollIntoView()
.should("be.visible") .should("be.visible")
.wait(1000) .wait(1000)
.get(PRODUCT_DETAILS.editVariant) .get(PRODUCT_DETAILS.editVariant)