JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="http://code.jquery.com/qunit/git/qunit.css">
<script src="http://code.jquery.com/qunit/git/qunit.js"></script>
<html>
<head>
<link rel="stylesheet" type="text/css" href="qunit.css" />
<title>cookbook QUnit Test</title>
<script type='text/javascript' src='qunit.js'></script>
<script type='text/javascript' src='jquery.js'></script>
<script type='text/javascript' src='test.js'></script>
</head>
<body>
<h1 id="qunit-header">Test Suite</h1>
<h2 id="qunit-banner"></h2>
<div id="qunit-testrunner-toolbar"></div>
<h2 id="qunit-userAgent"></h2>
<div id="test-content"></div>
<ol id="qunit-tests"></ol>
<div id="qunit-test-area"></div>
</body>
</html>
JavaScript
test("unload with other window", function(){
stop()
$('<iframe id="myframe" src="http://fiddle.jshell.net/UKEK7/show/"></iframe>').appendTo('#qunit-test-area').load(function(){
$($("#myframe")[0].contentWindow).bind("unload", function(){
ok(true, "called unload")
start();
})
$("#myframe").remove()
})
})