mirror of
https://github.com/microsoft/playwright.git
synced 2024-11-28 09:23:42 +03:00
chore: unflake 'should record' (#32880)
This commit is contained in:
parent
6f99d48a12
commit
6f16b6cc08
@ -126,6 +126,8 @@ export class RecorderCollection extends EventEmitter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private _fireChange() {
|
private _fireChange() {
|
||||||
|
if (!this._enabled)
|
||||||
|
return;
|
||||||
this.emit('change', collapseActions(this._actions));
|
this.emit('change', collapseActions(this._actions));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -188,9 +188,9 @@ test('test', async ({ page }) => {
|
|||||||
await page.getByRole('button', { name: 'Submit' }).click();
|
await page.getByRole('button', { name: 'Submit' }).click();
|
||||||
});`
|
});`
|
||||||
});
|
});
|
||||||
const length = events.length;
|
|
||||||
// No events after mode disabled
|
// No events after mode disabled
|
||||||
await backend.setRecorderMode({ mode: 'none' });
|
await backend.setRecorderMode({ mode: 'none' });
|
||||||
|
const length = events.length;
|
||||||
await page.getByRole('button').click();
|
await page.getByRole('button').click();
|
||||||
expect(events).toHaveLength(length);
|
expect(events).toHaveLength(length);
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user