Skip to content

Commit

Permalink
test: unflake webview tests (#6644)
Browse files Browse the repository at this point in the history
We close webviews after each test, for the safe `webViews().length` assertions.
  • Loading branch information
dgozman committed May 19, 2021
1 parent 475a417 commit e804d16
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/android/webview.spec.ts
Expand Up @@ -16,6 +16,10 @@

import { androidTest as test, expect } from './androidTest';

test.afterEach(async ({ androidDevice }) => {
await androidDevice.shell('am force-stop org.chromium.webview_shell');
});

test('androidDevice.webView', async function({ androidDevice }) {
expect(androidDevice.webViews().length).toBe(0);
await androidDevice.shell('am start org.chromium.webview_shell/.WebViewBrowserActivity');
Expand Down

0 comments on commit e804d16

Please sign in to comment.