mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 04:49:35 +00:00
web - guard against error from stopping tracing on tear down of tests
This commit is contained in:
parent
4b07dae7fd
commit
db4cda10a8
|
@ -43,8 +43,12 @@ function buildDriver(browser: playwright.Browser, context: playwright.BrowserCon
|
|||
capturePage: () => Promise.resolve(''),
|
||||
reloadWindow: (windowId) => Promise.resolve(),
|
||||
exitApplication: async () => {
|
||||
await context.tracing.stop({ path: join(logsPath, `playwright-trace-${traceCounter++}.zip`) });
|
||||
await browser.close();
|
||||
try {
|
||||
await context.tracing.stop({ path: join(logsPath, `playwright-trace-${traceCounter++}.zip`) });
|
||||
await browser.close();
|
||||
} catch (error) {
|
||||
console.error(error); // do not fail the build when this fails
|
||||
}
|
||||
await teardown();
|
||||
},
|
||||
dispatchKeybinding: async (windowId, keybinding) => {
|
||||
|
|
Loading…
Reference in a new issue