more de-flake
This commit is contained in:
@@ -394,9 +394,12 @@ describe('fields - relationship', () => {
|
||||
const button = field.locator(
|
||||
'button.relationship--single-value__drawer-toggler.doc-drawer__toggler',
|
||||
)
|
||||
|
||||
await wait(1000)
|
||||
|
||||
await button.click()
|
||||
|
||||
await wait(500)
|
||||
await wait(1000)
|
||||
|
||||
const documentDrawer = page.locator('[id^=doc-drawer_relation-one_1_]')
|
||||
await expect(documentDrawer).toBeVisible()
|
||||
|
||||
@@ -746,8 +746,7 @@ describe('fields', () => {
|
||||
.locator('.file-field__upload input[type="file"]')
|
||||
.setInputFiles(path.resolve(dirname, './collections/Upload/payload.jpg'))
|
||||
await expect(page.locator('.file-field .file-field__filename')).toHaveValue('payload.jpg')
|
||||
await page.locator('#action-save').click()
|
||||
await expect(page.locator('.Toastify')).toContainText('successfully')
|
||||
await saveDocAndAssert(page)
|
||||
}
|
||||
|
||||
// eslint-disable-next-line playwright/expect-expect
|
||||
@@ -766,7 +765,7 @@ describe('fields', () => {
|
||||
|
||||
test('should upload using the document drawer', async () => {
|
||||
await uploadImage()
|
||||
await wait(500)
|
||||
await wait(1000)
|
||||
// Open the media drawer and create a png upload
|
||||
|
||||
await openDocDrawer(page, '.field-type.upload .upload__toggler.doc-drawer__toggler')
|
||||
|
||||
@@ -132,7 +132,7 @@ export async function openNav(page: Page): Promise<void> {
|
||||
|
||||
export async function openDocDrawer(page: Page, selector: string): Promise<void> {
|
||||
await page.locator(selector).click()
|
||||
await wait(300) // wait for drawer form state to initialize
|
||||
await wait(1000) // wait for drawer form state to initialize
|
||||
}
|
||||
|
||||
export async function closeNav(page: Page): Promise<void> {
|
||||
|
||||
Reference in New Issue
Block a user