| Summary: | [EFL][WK2] Fix an unit test of ewk_context_url_scheme_register() | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Gyuyoung Kim <gyuyoung.kim> | ||||||||
| Component: | WebKit EFL | Assignee: | Gyuyoung Kim <gyuyoung.kim> | ||||||||
| Status: | RESOLVED FIXED | ||||||||||
| Severity: | Normal | CC: | bunhere, cdumez, commit-queue, gyuyoung.kim, lucas.de.marchi, sergio | ||||||||
| Priority: | P2 | ||||||||||
| Version: | 528+ (Nightly build) | ||||||||||
| Hardware: | Unspecified | ||||||||||
| OS: | Unspecified | ||||||||||
| Bug Depends on: | |||||||||||
| Bug Blocks: | 132813 | ||||||||||
| Attachments: |
|
||||||||||
|
Description
Gyuyoung Kim
2014-05-14 04:26:48 PDT
Created attachment 231443 [details]
WIP
Created attachment 231477 [details]
Patch
Comment on attachment 231477 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=231477&action=review > Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_context.cpp:128 > +#if ENABLE(CUSTOM_PROTOCOL) > ewk_context_url_scheme_register(ewk_view_context_get(webView()), "fooscheme", schemeRequestCallback, 0); > - ASSERT_TRUE(loadUrlSync("fooscheme:MyPath")); > - ASSERT_STREQ("Foo", ewk_view_title_get(webView())); > + ewk_view_url_set(webView(), "fooscheme:MyPath"); > + > + ASSERT_TRUE(waitUntilTrue(finishTest, testTimeoutSeconds)); > +#else > + ewk_context_url_scheme_register(ewk_view_context_get(webView()), "fooscheme", schemeRequestCallback, 0); > + ewk_view_url_set(webView(), "fooscheme:MyPath"); > + > + ASSERT_FALSE(waitUntilTrue(finishTest, testTimeoutSeconds)); > +#endif Does the test even need to run at all when custom protocols are disabled? I'd just put the entire test inside #if ENABLE(CUSTOM_PROTOCOL) and get rid of the #else block. Created attachment 231489 [details]
Patch for landing
(In reply to comment #3) > (From update of attachment 231477 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=231477&action=review > > > Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_context.cpp:128 > > +#if ENABLE(CUSTOM_PROTOCOL) > > ewk_context_url_scheme_register(ewk_view_context_get(webView()), "fooscheme", schemeRequestCallback, 0); > > - ASSERT_TRUE(loadUrlSync("fooscheme:MyPath")); > > - ASSERT_STREQ("Foo", ewk_view_title_get(webView())); > > + ewk_view_url_set(webView(), "fooscheme:MyPath"); > > + > > + ASSERT_TRUE(waitUntilTrue(finishTest, testTimeoutSeconds)); > > +#else > > + ewk_context_url_scheme_register(ewk_view_context_get(webView()), "fooscheme", schemeRequestCallback, 0); > > + ewk_view_url_set(webView(), "fooscheme:MyPath"); > > + > > + ASSERT_FALSE(waitUntilTrue(finishTest, testTimeoutSeconds)); > > +#endif > > Does the test even need to run at all when custom protocols are disabled? I'd just put the entire test inside #if ENABLE(CUSTOM_PROTOCOL) and get rid of the #else block. Removed #else block. Thanks. Comment on attachment 231489 [details] Patch for landing Clearing flags on attachment: 231489 Committed r168892: <http://trac.webkit.org/changeset/168892> All reviewed patches have been landed. Closing bug. |