Fix timing-sensitive WebView test and improve framework.
Fix WebViewTest#testJavascriptInterfaceCustomPropertiesClearedOnReload by using reloadAndWaitForCompletion() instead of reload(), so that the reload actually completes before we check the results - the timing of this changed slightly and the test became unreliable as a result. Also, improve EvaluateJsResultPollingCheck - instead of polling until the *expected* result is received, poll until *any* result is received and then check if the result is the same as the expected result. This means that in cases where the result is incorrect, it's reported by assertEquals as a failure with the expected and actual result shown in the test output, rather than appearing as a misleading timeout. Bug: 71710844 Test: run CtsWebkitTestCases Change-Id: I914089ba8cbbd094ad72f6dfed5ebf2176f9daf6 (cherry picked from commit f356a632)
Loading
Please sign in to comment