mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
Bug 560351 - Don't forget to actually throw the exception. r=peterv
--HG-- extra : rebase_source : 92f95ae32314cd74975dc2a932f67e617b4a7772
This commit is contained in:
parent
145742632c
commit
ceef5df2e4
@ -55,7 +55,7 @@ xpc_qsUnwrapThis<_interface>(JSContext *cx, \
|
||||
pThisRef, pThisVal, lccx, \
|
||||
&rv); \
|
||||
if(!native) \
|
||||
return JS_FALSE; \
|
||||
return xpc_qsThrow(cx, rv); \
|
||||
*ppThis = static_cast<_interface*>(native); \
|
||||
return JS_TRUE; \
|
||||
} \
|
||||
|
@ -71,6 +71,7 @@ _TEST_FILES = bug500931_helper.html \
|
||||
test_bug505915.html \
|
||||
test_bug517163.html \
|
||||
test_bug553407.html \
|
||||
test_bug560351.html \
|
||||
test_cows.html \
|
||||
test_frameWrapping.html \
|
||||
$(NULL)
|
||||
|
37
js/src/xpconnect/tests/mochitest/test_bug560351.html
Normal file
37
js/src/xpconnect/tests/mochitest/test_bug560351.html
Normal file
@ -0,0 +1,37 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<!--
|
||||
https://bugzilla.mozilla.org/show_bug.cgi?id=560351
|
||||
-->
|
||||
<head>
|
||||
<title>Test for Bug 560351</title>
|
||||
<script type="application/javascript" src="/MochiKit/packed.js"></script>
|
||||
<script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
|
||||
</head>
|
||||
<body>
|
||||
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=560351">Mozilla Bug 560351</a>
|
||||
<p id="display"></p>
|
||||
<div id="content" style="display: none">
|
||||
|
||||
</div>
|
||||
<pre id="test">
|
||||
<script type="application/javascript">
|
||||
|
||||
/** Test for Bug 560351 **/
|
||||
var pass = false;
|
||||
try {
|
||||
document.body.__lookupGetter__("lastChild")();
|
||||
} catch (e) {
|
||||
pass = true;
|
||||
}
|
||||
|
||||
</script>
|
||||
<script>
|
||||
|
||||
ok(pass, "pass was set to true");
|
||||
|
||||
</script>
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue
Block a user