| Index: LayoutTests/fast/cookies/cookies-disabled-in-data-url.html
|
| diff --git a/LayoutTests/fast/cookies/cookies-disabled-in-data-url.html b/LayoutTests/fast/cookies/cookies-disabled-in-data-url.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..2ee02af6fba827b86650caffe0f728b6fc0e1d89
|
| --- /dev/null
|
| +++ b/LayoutTests/fast/cookies/cookies-disabled-in-data-url.html
|
| @@ -0,0 +1,23 @@
|
| +<!DOCTYPE html>
|
| +<html>
|
| +<head>
|
| +</head>
|
| +<body>
|
| + <script src="../js/resources/js-test-pre.js"></script>
|
| + <script>
|
| + description("This tests that cookie access throws exceptions with reasonable messages inside 'data:' URLs.");
|
| +
|
| + window.jsTestIsAsync = true;
|
| +
|
| + var exceptionMessage;
|
| + window.addEventListener('message', function (e) {
|
| + exceptionMessage = e.data;
|
| + shouldBeEqualToString('exceptionMessage', "Access to 'cookie' is denied for this document. Cookies are disabled inside 'data:' URLs.");
|
| + finishJSTest();
|
| + });
|
| +
|
| + </script>
|
| + <iframe src="data:text/html,<script>try { document.cookie; } catch(e) { window.top.postMessage(e.message, '*'); };</script>"></iframe>
|
| + <script src="../js/resources/js-test-post.js"></script>
|
| +</body>
|
| +</html>
|
|
|