Commit ec35b909 authored by Jiewei Qian's avatar Jiewei Qian Committed by Chromium LUCI CQ

platform-apps: speculative fix flaky test

Speculative fix PlatformAppBrowserTest.OpenLink by registering
TabAddedWaiter before launching the App.

Bug: 1164123, 1000234
Change-Id: Ie1a303974d50941ca4cdc8382837e0ca86dd914e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2642645
Auto-Submit: Jiewei Qian  <qjw@chromium.org>
Commit-Queue: Ben Wells <benwells@chromium.org>
Reviewed-by: default avatarBen Wells <benwells@chromium.org>
Cr-Commit-Position: refs/heads/master@{#845972}
parent 75effde3
......@@ -811,16 +811,11 @@ IN_PROC_BROWSER_TEST_F(PlatformAppWithFileBrowserTest, LaunchNewFile) {
#endif // !BUILDFLAG(IS_CHROMEOS_ASH)
#if BUILDFLAG(IS_CHROMEOS_ASH)
// TODO(https://crbug.com/1000234): Re-enable this test.
#define MAYBE_OpenLink DISABLED_OpenLink
#else
#define MAYBE_OpenLink OpenLink
#endif
IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_OpenLink) {
IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, OpenLink) {
ASSERT_TRUE(StartEmbeddedTestServer());
ui_test_utils::TabAddedWaiter tab_added_waiter(browser());
LoadAndLaunchPlatformApp("open_link", "Launched");
ui_test_utils::TabAddedWaiter(browser()).Wait();
tab_added_waiter.Wait();
ASSERT_EQ(2, browser()->tab_strip_model()->count());
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment