| Index: LayoutTests/fast/dom/Window/post-message-to-self.html
|
| diff --git a/LayoutTests/fast/dom/Window/post-message-to-self.html b/LayoutTests/fast/dom/Window/post-message-to-self.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..d95ea1e28d16a87ca89c2491fcfaa69612b3dc2b
|
| --- /dev/null
|
| +++ b/LayoutTests/fast/dom/Window/post-message-to-self.html
|
| @@ -0,0 +1,31 @@
|
| +<html>
|
| +<head>
|
| +<script src="../../../resources/js-test.js"></script>
|
| +</head>
|
| +<body>
|
| +<script>
|
| +description("Test that window.postMessage() to self is not leaking.");
|
| +
|
| +window.jsTestIsAsync = true;
|
| +
|
| +if (window.testRunner) {
|
| + testRunner.dumpAsText();
|
| + testRunner.waitUntilDone();
|
| +}
|
| +
|
| +function postMessageToSelf() {
|
| + setInterval(function() {
|
| + window.postMessage("msg", "*");
|
| + }, 1);
|
| +}
|
| +
|
| +function receiveMessage(event) {
|
| + testPassed("Received message " + event.data);
|
| + finishJSTest();
|
| +}
|
| +
|
| +window.addEventListener("message", receiveMessage, false);
|
| +postMessageToSelf();
|
| +</script>
|
| +</body>
|
| +</html
|
|
|