blob: 8c4a9d82d6614b79550cee18b30c5bbaaa33918c [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/js-test.js"></script>
</head>
<body>
<script>
description("Tests that when a Geolocation request is made from a remote frame, and the JavaScript call chain starts from that remote frame, callbacks are made as usual.");
function onIframeReady() {
// Make request from remote frame, with call chain starting here
window.setTimeout(function() {
iframe.contentWindow.navigator.geolocation.getCurrentPosition(function() {
testPassed('Success callback invoked');
finishJSTest();
}, function() {
testFailed('Error callback invoked unexpectedly');
finishJSTest();
});
}, 0);
}
var iframe = document.createElement('iframe');
iframe.src = 'resources/callback-to-remote-context-inner.html';
document.body.appendChild(iframe);
window.jsTestIsAsync = true;
</script>
</body>
</html>