3 <script src=
"../../../resources/js-test.js"></script>
7 description("Checks that passing invalid strings to window.open() is properly handled.");
10 testRunner
.setCanOpenWindows();
12 var nonConvertibleToString
= { toString: function() { throw "Exception in toString()"; } };
14 shouldThrow("newWindow = window.open(nonConvertibleToString)", "'Exception in toString()'");
15 shouldBeNull("newWindow");
16 shouldThrow("newWindow = window.open('about:blank', nonConvertibleToString)", "'Exception in toString()'");
17 shouldBeNull("newWindow");
18 shouldThrow("newWindow = window.open('about:blank', 'frameName', nonConvertibleToString)", "'Exception in toString()'");
19 shouldBeNull("newWindow");