Closed Bug 806740 Opened 7 years ago Closed 7 years ago
_set And Fetch Favicon For Page _failures .js to the new per-tab PB APIs
http://mxr.mozilla.org/mozilla-central/source/toolkit/components/places/tests/favicons/test_setAndFetchFaviconForPage_failures.js In order to port this test, the file needs to be copied to the same directory (perhaps with "_perwindowpb" appended to its file name), and then instead of setting privateBrowsingEnabled, we need to open a new private browsing window and then run the test on that window. Note that the original test should only be added to the list of test files in Makefile.in ifndef MOZ_PER_WINDOW_PRIVATE_BROWSING, and the new test file should be added to the list with the reverse condition.
Removed this test from per-window PB builds: https://hg.mozilla.org/mozilla-central/rev/71646d15d610
This test was also modified a bit from its original form. I noticed the moz_favicons table is not empty at the beginning, so I added a check first (to make decisions later) because the last function of the test relied on the moz_favicons tables being empty. Please let me know if everything's OK with this test. Thanks.
Attachment #689462 - Flags: review?(ehsan)
Yeah, that could happen with any non-xpcshell test. The major difference is that non-xpcshell tests all run in the same browser session instead of each in their own session, so each test can be affected by everything that happened before it.
Comment on attachment 689462 [details] [diff] [review] Patch to migrate the test to the new per window private mode Review of attachment 689462 [details] [diff] [review]: ----------------------------------------------------------------- ::: toolkit/components/places/tests/favicons/test_setAndFetchFaviconForPage_failures.js @@ +10,5 @@ > + // Initialization > + waitForExplicitFinish(); > + let windowsToClose = ; > + let favIcon16Location = > + "http://example.org/tests/toolkit/components/places/tests/browser/favicon-normal16.png"; You need to include this file in the tests/browser directory. I'll do that before landing.
Attachment #689462 - Flags: review?(ehsan) → review+
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 20
You need to log in before you can comment on or make changes to this bug.