Backed out changeset a0fb9b7bcfe7 (bug 1534343) for mochitest failures at netwerk/cookie/test/mochitest/test_xmlDocument.html on a CLOSED TREE
authorCoroiu Cristina <ccoroiu@mozilla.com>
Tue, 19 Mar 2019 14:17:03 +0200
changeset 465024 7da042469ac075f8504be068c505ff0a868a8b77
parent 465023 e94a55919deaae4fa117d64dd9404f4e85dad7fd
child 465025 ae44c37e9e21baffc99e3557ed7f1b0a64f7d6e7
push id80837
push userccoroiu@mozilla.com
push dateTue, 19 Mar 2019 12:17:19 +0000
treeherderautoland@7da042469ac0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1534343
milestone68.0a1
backs outa0fb9b7bcfe70ab1c035e23a79c9f86b6efdd078
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out changeset a0fb9b7bcfe7 (bug 1534343) for mochitest failures at netwerk/cookie/test/mochitest/test_xmlDocument.html on a CLOSED TREE
dom/base/Document.cpp
netwerk/cookie/test/mochitest/mochitest.ini
netwerk/cookie/test/mochitest/test_xmlDocument.html
--- a/dom/base/Document.cpp
+++ b/dom/base/Document.cpp
@@ -11825,17 +11825,17 @@ void Document::SetDocTreeHadPlayRevoked(
   }
 }
 
 DocumentAutoplayPolicy Document::AutoplayPolicy() const {
   return AutoplayPolicy::IsAllowedToPlay(*this);
 }
 
 void Document::MaybeAllowStorageForOpenerAfterUserInteraction() {
-  if (CookieSettings()->GetCookieBehavior() !=
+  if (mCookieSettings->GetCookieBehavior() !=
       nsICookieService::BEHAVIOR_REJECT_TRACKER) {
     return;
   }
 
   // This will probably change for project fission, but currently this document
   // and the opener are on the same process. In the future, we should make this
   // part async.
 
@@ -12347,17 +12347,17 @@ already_AddRefed<mozilla::dom::Promise> 
 
   // Step 2. If the document has a null origin, reject.
   if (NodePrincipal()->GetIsNullPrincipal()) {
     promise->MaybeRejectWithUndefined();
     return promise.forget();
   }
 
   // Only enforce third-party checks when there is a reason to enforce them.
-  if (CookieSettings()->GetCookieBehavior() !=
+  if (mCookieSettings->GetCookieBehavior() !=
       nsICookieService::BEHAVIOR_REJECT_TRACKER) {
     // Step 3. If the document's frame is the main frame, resolve.
     if (IsTopLevelContentDocument()) {
       promise->MaybeResolveWithUndefined();
       return promise.forget();
     }
 
     // Step 4. If the sub frame's origin is equal to the main frame's, resolve.
@@ -12400,17 +12400,17 @@ already_AddRefed<mozilla::dom::Promise> 
 
   if (nsContentUtils::IsInPrivateBrowsing(this)) {
     // If the document is in PB mode, it doesn't have access to its persistent
     // cookie jar, so reject the promise here.
     promise->MaybeRejectWithUndefined();
     return promise.forget();
   }
 
-  if (CookieSettings()->GetCookieBehavior() ==
+  if (mCookieSettings->GetCookieBehavior() ==
           nsICookieService::BEHAVIOR_REJECT_TRACKER &&
       inner) {
     // Only do something special for third-party tracking content.
     if (nsContentUtils::StorageDisabledByAntiTracking(this, nullptr)) {
       // Note: If this has returned true, the top-level document is guaranteed
       // to not be on the Content Blocking allow list.
       DebugOnly<bool> isOnAllowList = false;
       // If we have a parent document, it has to be non-private since we
--- a/netwerk/cookie/test/mochitest/mochitest.ini
+++ b/netwerk/cookie/test/mochitest/mochitest.ini
@@ -6,9 +6,8 @@ support-files =
 
 [test_document_cookie.html]
 [test_fetch.html]
 [test_image.html]
 [test_script.html]
 [test_sharedWorker.html]
 [test_worker.html]
 [test_xhr.html]
-[test_xmlDocument.html]
deleted file mode 100644
--- a/netwerk/cookie/test/mochitest/test_xmlDocument.html
+++ /dev/null
@@ -1,25 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<head>
-  <title>Test for Document constructor</title>
-  <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
-</head>
-<body>
-<script type="application/javascript">
-
-SpecialPowers.pushPrefEnv({set: [
-  ["dom.storage_access.enabled", true],
-]}).then(_ => {
-  const doc = new Document();
-  doc.requestStorageAccess().catch(__ => {}).then(___ => {
-    ok(true, "No crash!");
-    SimpleTest.finish();
-  });
-});
-
-SimpleTest.waitForExplicitFinish();
-
-</script>
-</body>
-</html>