blob: bd8b6a427c33db492da6ba3d5d2d1155509911d4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
<!DOCTYPE html>
<html>
<head>
<script src="../../resources/js-test.js"></script>
<script>
if ('internals' in window) {
window.internals.settings.setSyncXHRInDocumentsEnabled(false);
} else {
document.write('This test depends on the syncXHRInDocumentsEnabled setting being false, so run in DumpRenderTree or manually enable it');
}
description('This tests that synchronous XMLHttpRequests fail when they are disabled for documents.');
var xhr = new XMLHttpRequest();
shouldThrow('xhr.open("GET", "http://mydomain/", false)');
</script>
</head>
<body>
<div id="description"></div>
<div id="console"></div>
</body>
</html>
|