On Sep 26, 2012, at 4:15 PM, Simon Fraser <[email protected]> wrote:

> On Sep 26, 2012, at 4:13 PM, Brady Eidson <[email protected]> wrote:
> 
>> This works for any preference;  Even a new one that has never been twiddled 
>> in a regression test before.
>> 
>> For example in http://trac.webkit.org/changeset/127956 we added a new test 
>> that twiddled the "WebKitStorageBlockingPolicy" preference and we didn't 
>> need to change any DRT Mac code to accomplish this.
>> 
>> Compared to adding a single implementation to internal.settings, this was 
>> *NO* additional work.
> 
> But is there code to undo this pref change for subsequent tests?

I looked into the mechanism that does this.

On Sep 26, 2012, at 1:44 PM, Simon Fraser <[email protected]> wrote:

> I looked at testRunner.overridePreference(), and it doesn't appear to reset 
> the value at the end of the test.

That happens elsewhere, in:
static void resetDefaultsToConsistentValues()

Indeed, each individual pref is currently managed with unique API calls here, 
and the example I provided of WebKitStorageBlockingPolicy leaks.

However, the key/value based preference mechanism can easily be augmented 
within DRT in a general way that will fix this and all future key/value 
preference usage.  That change would only have to happen once per port 
(assuming the port supports key/value based prefs)

 Brady

_______________________________________________
webkit-dev mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-dev

Reply via email to