RESOLVED FIXED 66307
Support reset in WebCore::Internals
https://bugs.webkit.org/show_bug.cgi?id=66307
Summary Support reset in WebCore::Internals
Chang Shu
Reported 2011-08-16 08:24:20 PDT
WebCore settings may have been modified through window.internals and DRT should be able to reset them back to their original values before each test run. The above support provides a framework so that Internals can restore the original values automatically.
Attachments
fix patch (7.95 KB, patch)
2011-08-16 09:10 PDT, Chang Shu
dglazkov: review-
fix patch 2 (12.04 KB, patch)
2011-08-16 13:02 PDT, Chang Shu
dglazkov: review+
patch 3: reviewed with minor fix (12.89 KB, patch)
2011-08-17 11:30 PDT, Chang Shu
no flags
Chang Shu
Comment 1 2011-08-16 09:10:03 PDT
Created attachment 104054 [details] fix patch The patch works for mac and qt.
WebKit Review Bot
Comment 2 2011-08-16 09:12:54 PDT
Attachment 104054 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1 Source/WebCore/testing/js/WebCoreTestSupport.cpp:59: One line control clauses should not use braces. [whitespace/braces] [4] Total errors found: 1 in 11 files If any of these errors are false positives, please file a bug against check-webkit-style.
Dimitri Glazkov (Google)
Comment 3 2011-08-16 09:45:43 PDT
Comment on attachment 104054 [details] fix patch This is a great start. We shouldn't land this with partial port support though. Cross-port support is the whole point of window.internals.
Chang Shu
Comment 4 2011-08-16 13:02:01 PDT
Created attachment 104078 [details] fix patch 2
Dimitri Glazkov (Google)
Comment 5 2011-08-17 10:59:44 PDT
Comment on attachment 104078 [details] fix patch 2 View in context: https://bugs.webkit.org/attachment.cgi?id=104078&action=review > Source/WebCore/testing/js/WebCoreTestSupport.cpp:54 > + Internals * internals = toInternals(globalObject->getDirect(exec->globalData(), Identifier(exec, "internals"))); Now that we're using it in more than one place, the literal should probably be a constant in this file. > Source/WebCore/testing/v8/WebCoreTestSupport.cpp:53 > + v8::Handle<v8::Object> object = v8::Handle<v8::Object>::Cast(context->Global()->Get(v8::String::New("internals"))); Ditto.
Chang Shu
Comment 6 2011-08-17 11:30:37 PDT
Created attachment 104200 [details] patch 3: reviewed with minor fix
Chang Shu
Comment 7 2011-08-17 13:05:22 PDT
Manually committed r93235: <http://trac.webkit.org/changeset/93235> Clearing flags.
Note You need to log in before you can comment on or make changes to this bug.