When writing to alt-data output stream fails for whatever reason, we now try to
truncate alternative data and keep the original data instead of dooming the
whole entry. The patch also changes how is the predicted size passed to the
cache. Instead of a dedicated method it's now an argument of openOutputStream
and openAlternativeOutputStream methods which fail in case the entry would
exceed the allowed limit.
These issues were previously ignored due to the nature of our global import
rules. They need to be fixed before that rule can be updated.
MozReview-Commit-ID: DCChktTc5TW
This patch fixes a bunch of intermittent/perma failures in sanitize-offlineData.js by:
- Ignoring localStorage for now. LocalStorage is cleared by sending an
observer notification. The flush often happens after several seconds, heavily
interfering with our own test or with subsequent tests. We can not reliably wait
on the operation to finish. Waiting for "domstorage-test-flushed" after calling
Sanitizer.sanitize() fixes the problem, but that notification is intermittently
not triggered for other unknown reasons, which makes it not really viable to use.
- Creating and checking indexedDB data in the chrome process (using SiteDataTestUtils).
- Cleaning up after running the test.
- Ignoring a stray NS_ERROR_ABORT that's hard to track down and doesn't seem to
do any damage right now.
I've also moved the ServiceWorker utility functions into SiteDataTestUtils,
which we're planning to use in all other browser tests that handle site data.
This commit adds a helper module for doing common tasks
related to site data, such as adding dummy data and getting usage.
There are many places that would potentially need to be cleaned
up to use this module instead, but I consider that work (and the
likely try failure fallout) out of scope for this bug.
MozReview-Commit-ID: 5eMDgHhClsO
This removes the sync reflow from almost all cases. The only case where we keep it is when a keypress
caught in content triggers a sync message to the parent process. We should clean this up in bug 1371523.
I've tried to fix the tests, but a lot of them seem to be disabled anyway...
MozReview-Commit-ID: 9k36p7q8MKy
This removes the sync reflow from almost all cases. The only case where we keep it is when a keypress
caught in content triggers a sync message to the parent process. We should clean this up in bug 1371523.
I've tried to fix the tests, but a lot of them seem to be disabled anyway...
MozReview-Commit-ID: 9k36p7q8MKy
We're changing the way sanitize.js/Sanitizer.jsm works and need to adjust a lot of tests to that.
I'm using this opportunity to also move the sanitization tests into their
own topical directory and out of b/b/c/test/general.
MozReview-Commit-ID: GHOqr4hT52b