test: ensure fullscreen test is retryable (#37179)
spec: ensure fullscreen test is retryable
This commit is contained in:
parent
a15c9d3058
commit
8b380ee2f2
1 changed files with 6 additions and 4 deletions
|
@ -2270,17 +2270,19 @@ describe('iframe using HTML fullscreen API while window is OS-fullscreened', ()
|
||||||
);
|
);
|
||||||
let w: BrowserWindow, server: http.Server;
|
let w: BrowserWindow, server: http.Server;
|
||||||
|
|
||||||
before(() => {
|
beforeEach(async () => {
|
||||||
server = http.createServer(async (_req, res) => {
|
server = http.createServer(async (_req, res) => {
|
||||||
res.writeHead(200, { 'Content-Type': 'text/html' });
|
res.writeHead(200, { 'Content-Type': 'text/html' });
|
||||||
res.write(await fullscreenChildHtml);
|
res.write(await fullscreenChildHtml);
|
||||||
res.end();
|
res.end();
|
||||||
});
|
});
|
||||||
|
|
||||||
server.listen(8989, '127.0.0.1');
|
await new Promise<void>((resolve) => {
|
||||||
});
|
server.listen(8989, '127.0.0.1', () => {
|
||||||
|
resolve();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
beforeEach(() => {
|
|
||||||
w = new BrowserWindow({
|
w = new BrowserWindow({
|
||||||
show: true,
|
show: true,
|
||||||
fullscreen: true,
|
fullscreen: true,
|
||||||
|
|
Loading…
Reference in a new issue