mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-27 10:42:45 +03:00
Revert "Removed explicit timeout for offer creation helper"
This reverts commit ac427e4253
.
This commit is contained in:
parent
ac427e4253
commit
6f9f83bee8
@ -14,7 +14,6 @@
|
||||
@triggerClass="gh-contentfilter-menu-trigger"
|
||||
@dropdownClass="gh-contentfilter-menu-dropdown"
|
||||
@matchTriggerWidth={{false}}
|
||||
data-testid="offers-type-select"
|
||||
as |type|
|
||||
>
|
||||
{{#if type.name}}{{type.name}} offers{{else}}<span class="red">Unknown type</span>{{/if}}
|
||||
|
@ -295,11 +295,13 @@ const createOffer = async (page, {name, tierName, offerType, amount, discountTyp
|
||||
.getByRole('button', {name: 'Archive'})
|
||||
.click();
|
||||
|
||||
// waiting for offer to be archived
|
||||
await expect(await page.locator('.modal-content')).toBeHidden();
|
||||
|
||||
await expect(await page.getByTestId('offers-type-select')).toBeVisible();
|
||||
await page.getByTestId('offers-type-select').click();
|
||||
// TODO: Use a more resilient selector
|
||||
const statusDropdown = await page.getByRole('button', {name: 'Archived offers'});
|
||||
await statusDropdown.waitFor({
|
||||
state: 'visible',
|
||||
timeout: 1000
|
||||
});
|
||||
await statusDropdown.click();
|
||||
await page.getByRole('option', {name: 'Active offers'}).click();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user