Index: third_party/WebKit/LayoutTests/http/tests/navigation/pushstate-whitelisted-in-blob-denied.html |
diff --git a/third_party/WebKit/LayoutTests/http/tests/navigation/pushstate-whitelisted-in-blob-denied.html b/third_party/WebKit/LayoutTests/http/tests/navigation/pushstate-whitelisted-in-blob-denied.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..db5ae2de5dbf1a6179ad4440b397294e8d1c15d0 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/http/tests/navigation/pushstate-whitelisted-in-blob-denied.html |
@@ -0,0 +1,15 @@ |
+<script src="../resources/testharness.js"></script> |
+<script src="../resources/testharnessreport.js"></script> |
+<script> |
+test(function () { |
+ testRunner.addOriginAccessWhitelistEntry(location.origin, location.protocol, '', false); |
+ testRunner.addOriginAccessWhitelistEntry(location.origin, 'blob', '', false); |
+}, 'testRunner.addOriginAccessWhitelistEntry is required for this test'); |
+ |
+test(function () { |
+ var blobUrl = URL.createObjectURL(new Blob()); |
+ assert_throws('SecurityError', function () { |
+ history.pushState(null, null, blobUrl); |
+ }); |
+}, 'pushState to blob:-URL should fail with SecurityError (even with whitelisted origins)'); |
+</script> |