Chromium Code Reviews| Index: LayoutTests/screen_orientation/resources/sandboxed-iframe-locking.html |
| diff --git a/LayoutTests/screen_orientation/resources/sandboxed-iframe-locking.html b/LayoutTests/screen_orientation/resources/sandboxed-iframe-locking.html |
| index cc931a49fb8f982d2799fc4e92b20161486be216..7ba8d37c56b37a9a63cf07c9bcc5fa55dae8d346 100644 |
| --- a/LayoutTests/screen_orientation/resources/sandboxed-iframe-locking.html |
| +++ b/LayoutTests/screen_orientation/resources/sandboxed-iframe-locking.html |
| @@ -1,9 +1,14 @@ |
| <script> |
|
jochen (gone - plz use gerrit)
2014/05/22 08:34:35
please add <!DOCTYPE html>
mlamouri (slow - plz ping)
2014/05/22 08:58:56
Done.
|
| - var exceptionName = ""; |
| - try { |
| - screen.lockOrientation("portrait-primary"); |
| - } catch (ex) { |
| - exceptionName = ex.name; |
| - } |
| - parent.window.postMessage(exceptionName, "*"); |
| + var msg = ""; |
| + screen.lockOrientation("portrait-primary").then(function() { |
| + }, function(error) { |
| + msg = error.name; |
| + }); |
| + |
| + // FIXME: for the moment, tests gets notified when there is a failure but |
| + // not a success, this hack should allow us to still have the test running. |
| + // That should be removed as soon as we get a resolved promise in tests. |
| + setTimeout(function() { |
| + parent.window.postMessage(msg, "*"); |
| + }) |
| </script> |