Fix VpnProviderApiTest.DestroyConnectedConfig
Fix the flakiness in the VpnProviderApiTest.DestroyConnectedConfig test caused by the C++ side missing the JS test success notification. In a detail, the test was first deleting the VPN config - which triggers the "disconnected" vpnProvider.onPlatformMessage event and the test's test.succeed() call - and then creating a ResultCatcher afterwards. With unlucky timing, all of the steps, including the test.succeed() event arrival to the browser process, were happening before the ResultCatcher was constructed. The fix is therefore to move the construction of the ResultCatcher to happen earlier, before deleting the VPN config. Bug: 1108527 Test: run "browser_process --gtest_filter=VpnProviderApiTest.DestroyConnectedConfig" under stress a thousand times Change-Id: Ib26da605dc379240b8925f275bd22d96aadd99e4 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2315337 Auto-Submit: Maksim Ivanov <emaxx@chromium.org> Commit-Queue: Andreea-Elena Costinas <acostinas@google.com> Reviewed-by:Andreea-Elena Costinas <acostinas@google.com> Cr-Commit-Position: refs/heads/master@{#791177}
Showing
Please register or sign in to comment