Skip to content

Commit 86b237d

Browse files
committed
[services/remote] wrap up clearing storage with try/catch
1 parent 9769be3 commit 86b237d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/functional/services/remote/remote.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ export async function RemoteProvider({ getService }: FtrProviderContext) {
128128
.manage()
129129
.window()
130130
.setRect({ width, height });
131-
await driver.executeScript('window.sessionStorage.clear();');
132-
await driver.executeScript('window.localStorage.clear();');
131+
await driver.executeScript('try { window.sessionStorage.clear(); } catch (err) {};');
132+
await driver.executeScript('try { window.localStorage.clear(); } catch (err) {};');
133133
});
134134

135135
lifecycle.on('cleanup', async () => {

0 commit comments

Comments
 (0)