forked from woocommerce/woocommerce
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[e2e tests] Replace utils from the new `@woocommerce/e2e-utils-playwr…
…ight` package (woocommerce#53377)
- Loading branch information
1 parent
ccd5f72
commit d837888
Showing
26 changed files
with
203 additions
and
97 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Significance: minor | ||
Type: dev | ||
|
||
Update existing tests with the Playwright utils from the @woocommerce/e2e-utils-playwright package |
6 changes: 5 additions & 1 deletion
6
plugins/woocommerce/tests/e2e-pw/tests/merchant/command-palette.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 9 additions & 3 deletions
12
plugins/woocommerce/tests/e2e-pw/tests/merchant/create-cart-block.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 11 additions & 5 deletions
16
plugins/woocommerce/tests/e2e-pw/tests/merchant/create-checkout-block.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 9 additions & 6 deletions
15
plugins/woocommerce/tests/e2e-pw/tests/merchant/create-page.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 10 additions & 7 deletions
17
plugins/woocommerce/tests/e2e-pw/tests/merchant/create-woocommerce-blocks.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 10 additions & 7 deletions
17
plugins/woocommerce/tests/e2e-pw/tests/merchant/create-woocommerce-patterns.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 5 additions & 1 deletion
6
plugins/woocommerce/tests/e2e-pw/tests/shopper/add-to-cart.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 9 additions & 5 deletions
14
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-block-calculate-shipping.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 9 additions & 5 deletions
14
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-block-coupons.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 9 additions & 5 deletions
14
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-block.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 4 additions & 1 deletion
5
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-calculate-shipping.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 10 additions & 6 deletions
16
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-checkout-block-calculate-tax.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 5 additions & 1 deletion
6
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-checkout-calculate-tax.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 4 additions & 1 deletion
5
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-checkout-coupons.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 7 additions & 2 deletions
9
plugins/woocommerce/tests/e2e-pw/tests/shopper/cart-checkout-restricted-coupons.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 8 additions & 5 deletions
13
plugins/woocommerce/tests/e2e-pw/tests/shopper/checkout-block-coupons.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 11 additions & 10 deletions
21
plugins/woocommerce/tests/e2e-pw/tests/shopper/checkout-block.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,23 @@ | ||
const { | ||
goToPageEditor, | ||
fillPageTitle, | ||
insertBlockByShortcut, | ||
publishPage, | ||
} = require( '../../utils/editor' ); | ||
const { addAProductToCart } = require( '../../utils/cart' ); | ||
const { fillPageTitle } = require( '../../utils/editor' ); | ||
const { test: baseTest, expect } = require( '../../fixtures/fixtures' ); | ||
|
||
const wcApi = require( '@woocommerce/woocommerce-rest-api' ).default; | ||
const { admin, customer } = require( '../../test-data/data' ); | ||
const { logIn } = require( '../../utils/login' ); | ||
const { setFilterValue, clearFilters } = require( '../../utils/filters' ); | ||
|
||
const { | ||
/** | ||
* External dependencies | ||
*/ | ||
import { | ||
insertBlockByShortcut, | ||
goToPageEditor, | ||
publishPage, | ||
addAProductToCart, | ||
getOrderIdFromUrl, | ||
fillShippingCheckoutBlocks, | ||
fillBillingCheckoutBlocks, | ||
} = require( '../../utils/checkout' ); | ||
const { getOrderIdFromUrl } = require( '../../utils/order' ); | ||
} from '@woocommerce/e2e-utils-playwright'; | ||
|
||
const guestEmail = '[email protected]'; | ||
const newAccountEmail = `marge-${ new Date() | ||
|
10 changes: 8 additions & 2 deletions
10
plugins/woocommerce/tests/e2e-pw/tests/shopper/checkout-create-account.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,14 @@ | ||
const { test, expect } = require( '@playwright/test' ); | ||
const wcApi = require( '@woocommerce/woocommerce-rest-api' ).default; | ||
const { admin } = require( '../../test-data/data' ); | ||
const { getOrderIdFromUrl } = require( '../../utils/order' ); | ||
const { addAProductToCart } = require( '../../utils/cart' ); | ||
|
||
/** | ||
* External dependencies | ||
*/ | ||
import { | ||
addAProductToCart, | ||
getOrderIdFromUrl, | ||
} from '@woocommerce/e2e-utils-playwright'; | ||
|
||
const billingEmail = '[email protected]'; | ||
|
||
|
9 changes: 7 additions & 2 deletions
9
plugins/woocommerce/tests/e2e-pw/tests/shopper/checkout-login.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.