Fix block editor variable product test
This commit is contained in:
parent
bc18547e81
commit
cd004530a7
|
@ -0,0 +1,4 @@
|
|||
Significance: patch
|
||||
Type: fix
|
||||
|
||||
Fixes for some flaky e2e
|
|
@ -196,10 +196,9 @@ test.describe( 'Variations tab', () => {
|
|||
await clickOnTab( 'Variations', page );
|
||||
|
||||
await page
|
||||
.locator(
|
||||
'.woocommerce-variations-table-error-or-empty-state__actions'
|
||||
)
|
||||
.getByRole( 'button', { name: 'Generate from options' } )
|
||||
.getByRole( 'button', {
|
||||
name: 'Generate from options',
|
||||
} )
|
||||
.click();
|
||||
|
||||
await clickOnTab( 'Variations', page );
|
||||
|
@ -215,21 +214,17 @@ test.describe( 'Variations tab', () => {
|
|||
.getByRole( 'button', { name: 'Pricing' } )
|
||||
.click();
|
||||
|
||||
const regularPrice = page.locator( 'input[name="regular_price"]' );
|
||||
await regularPrice.waitFor( { state: 'visible' } );
|
||||
await regularPrice.first().click();
|
||||
await regularPrice.first().fill( '100' );
|
||||
await page
|
||||
.getByLabel( 'Regular price', { exact: true } )
|
||||
.fill( '100' );
|
||||
|
||||
await page
|
||||
.locator( '.woocommerce-product-tabs' )
|
||||
.getByRole( 'button', { name: 'Inventory' } )
|
||||
.click();
|
||||
|
||||
const sku = page.locator( 'input[name="woocommerce-product-sku"]' );
|
||||
await sku.waitFor( { state: 'visible' } );
|
||||
await sku.first().click();
|
||||
await sku
|
||||
.first()
|
||||
await page
|
||||
.locator( '#inspector-input-control-2' )
|
||||
.fill( `product-sku-${ new Date().getTime().toString() }` );
|
||||
|
||||
await page
|
||||
|
@ -347,9 +342,8 @@ test.describe( 'Variations tab', () => {
|
|||
);
|
||||
|
||||
await page
|
||||
.locator( '.woocommerce-product-variations__table-body > div' )
|
||||
.getByRole( 'link', { name: 'Edit', exact: true } )
|
||||
.first()
|
||||
.getByText( 'Edit' )
|
||||
.click();
|
||||
|
||||
const notices = page.getByText(
|
||||
|
|
Loading…
Reference in New Issue