| <html> |
| <head> |
| <script> |
| function log(message) |
| { |
| document.getElementById("console").innerHTML += message + "<br>"; |
| } |
| |
| function finishTest() |
| { |
| if (window.layoutTestController) |
| layoutTestController.notifyDone(); |
| } |
| |
| function runTest() |
| { |
| if (window.layoutTestController) { |
| layoutTestController.dumpAsText(); |
| layoutTestController.waitUntilDone(); |
| } |
| |
| if (window.location.search == "?2") { |
| var worker = new Worker("resources/change-version-sync-2.js"); |
| worker.onmessage = function(event) { |
| if (event.data == "done") |
| finishTest(); |
| else |
| log(event.data); |
| }; |
| } else { |
| var worker = new Worker("resources/change-version-sync-1.js"); |
| worker.onmessage = function(event) { |
| if (event.data == "done") |
| window.location.href = window.location + "?2"; |
| else if (event.data == "fail") |
| finishTest(); |
| else |
| log(event.data); |
| }; |
| } |
| } |
| </script> |
| </head> |
| <body onload="runTest()"> |
| Test that version updates in sync databases work correctly. |
| <pre id="console"> |
| </pre> |
| </body> |
| </html> |