12021-08-01 Lauro Moura <lmoura@igalia.com>
2
3 [GLIB] Make CORS allowlist test wait for promise resolution
4 https://bugs.webkit.org/show_bug.cgi?id=228695
5
6 Reviewed by NOBODY (OOPS!).
7
8 r278456 introduced a CORS allow list test that tries to fetch a
9 resource using the fetch() function, which returns a promise. This is
10 working on GTK but in WPE the test fails as the promise is not yet
11 resolved by the time the test variable is checked.
12
13 This commit changes the test to actually report the promise failure
14 through catch() and wait for its resolution before checking the values.
15
16 * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
17 (testWebViewCORSAllowlist):
18