[Webkit-unassigned] [Bug 117728] [EFL][WK2] Implement unit test callback: onSettingChange

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jun 18 03:40:16 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=117728





--- Comment #3 from Krzysztof Wolanski <k.wolanski at samsung.com>  2013-06-18 03:38:52 PST ---
(From update of attachment 204892)
View in context: https://bugs.webkit.org/attachment.cgi?id=204892&action=review

>> Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:238
>> +            break;
> 
> maybe we could return here and add a "FAIL();" after the loop to make sure we found the item?

I will add ADD_FAILURE(), because FAIL() should not be used in functions that return non void value.

>> Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:283
>> +            selectContextMenuOption(ewk_context_menu_item_submenu_get(item), EWK_CONTEXT_MENU_ITEM_TAG_CHECK_SPELLING_WHILE_TYPING, EWK_CHECKABLE_ACTION_TYPE);
> 
> why not pass the item directly to selectContextMenuOption() instead of iterating over the list twice?

Because "Check Spelling While Typing" is in sub menu. First we should get sub menu from "Spelling and Grammar", and then toggle "Check Spelling While Typing" option.

>> Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:409
>> +    ASSERT_FALSE(waitUntilTrue(callbacksExecutionStats.settingChange, defaultTimeoutInSeconds));
> 
> this looks weird. are we waiting to make sure the callback is *not* called? if so, isn't is terribly slow? also, the last arg is likely optional.

We want to call callback, when *Check Spelling While Typing* is toggled in context menu. When client invokes ewk_text_checker_continuous_spell_checking_enabled_set(), callback should not be called.
Yes, the last argument is optional and by default is 10 seconds. I have changed it to 0.5 sec. It is enough.

>> Source/WebKit2/UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:426
>> +    ASSERT_FALSE(waitUntilTrue(callbacksExecutionStats.settingChange, defaultTimeoutInSeconds));
> 
> ditto.

Callback should not be called, defaultTimeoutInSeconds = 0.5. Do you suggest to remove this test?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list