On Thu, May 19, 2016 at 4:09 PM, Matthew N. <ma...@mozilla.com> wrote:

> As a reminder, the nice thing about pushPrefEnv is that the pref changes
> are reverted at the end of the test file which avoids them leaking into
> other tests unintentionally.
>

Another good thing about it is that set*Pref isn't actually synchronous in
the e10s content process, so you can end up with the pref not being set at
the right time. (IIRC the set pref sends a message to the parent telling it
to update the pref, but then continues running before the parent sends a
message back down to the child to actually set the child process pref.)

Andrew


> There are various places in the tree which wrote their own Promise
> wrappers for pushPrefEnv so feel free to file follow-up bugs blocking bug
> 1197310 to remove them.
>
> Cheers,
> Matthew N. (:MattN)
>
> [1] https://bugzilla.mozilla.org/show_bug.cgi?id=1197310
>
> P.S. For those of you who didn't hear (since there was no announcement),
> you can use add_task in mochitest-plain and mochitest-chrome thanks to bug
> 1187701 if you load …/tests/SimpleTest/SpawnTask.js.
> _______________________________________________
> dev-platform mailing list
> dev-platform@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-platform
>
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to