Remove after all scenario

This commit is contained in:
Veljko 2021-03-19 17:29:48 +01:00
parent dc23f3a522
commit d578914a9d
1 changed files with 1 additions and 9 deletions

View File

@ -109,17 +109,9 @@ const runImportProductsTest = () => {
// Compare overriden product prices
expect(productPrices.sort()).toEqual(productPricesOverride.sort());
});
afterAll(async () => {
// Remove all the imported products
await page.waitForSelector('#cb-select-all-1', {visible:true});
// Move all imported products to trash
await moveAllItemsToTrash();
await page.waitForSelector('ul.subsubsub li.trash a', {visible:true});
await page.click('ul.subsubsub li.trash a');
await page.waitForSelector('#delete_all', {visible:true});
await page.click('#delete_all');
await page.waitForSelector('a.woocommerce-BlankState-cta.button-primary.button ~ a', {visible:true});
});
});
};