tests and resources for bug 100533.
git-svn-id: svn://10.0.0.236/trunk@214332 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
8c6038a512
commit
595cff9a0b
8
mozilla/testing/mochitest/static/bug100533_iframe.html
Normal file
8
mozilla/testing/mochitest/static/bug100533_iframe.html
Normal file
@ -0,0 +1,8 @@
|
||||
<html>
|
||||
<head>
|
||||
<title></title>
|
||||
</head>
|
||||
<body>
|
||||
<form method='get' action='/static/bug100533_load.html' id='b'><input type="submit"/></form>
|
||||
</body>
|
||||
</html>
|
||||
14
mozilla/testing/mochitest/static/bug100533_load.html
Normal file
14
mozilla/testing/mochitest/static/bug100533_load.html
Normal file
@ -0,0 +1,14 @@
|
||||
<html>
|
||||
<head>
|
||||
<title></title>
|
||||
</head>
|
||||
|
||||
|
||||
<body onload="parent.submitted();">
|
||||
|
||||
<span id="foo"></span>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@ -44,6 +44,7 @@ if (!params.quiet) {
|
||||
var RunSet = {}
|
||||
RunSet.runall = function() {
|
||||
TestRunner.runTests(
|
||||
'test_bug100533.html',
|
||||
'test_bug218277.html',
|
||||
'test_bug302186.html',
|
||||
'test_bug338541.xhtml',
|
||||
|
||||
44
mozilla/testing/mochitest/tests/test_bug100533.html
Normal file
44
mozilla/testing/mochitest/tests/test_bug100533.html
Normal file
@ -0,0 +1,44 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<!--
|
||||
https://bugzilla.mozilla.org/show_bug.cgi?id=100533
|
||||
-->
|
||||
<head>
|
||||
<title>Test for Bug 100533</title>
|
||||
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
||||
<script type="text/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=100533">Mozilla Bug 100533</a>
|
||||
<p id="display"></p>
|
||||
<div id="content" >
|
||||
|
||||
<button id="thebutton">Test</button>
|
||||
<iframe style='display: none;' src='/static/bug100533_iframe.html' id='a'></iframe>
|
||||
|
||||
</div>
|
||||
<pre id="test">
|
||||
<script class="testbody" type="text/javascript">
|
||||
|
||||
SimpleTest.waitForExplicitFinish();
|
||||
|
||||
/** Test for Bug 100533 **/
|
||||
var submitIframeForm = function() {
|
||||
$('a').contentDocument.getElementById('b').submit();
|
||||
}
|
||||
|
||||
submitted = function() {
|
||||
ok(true, "Finished. Form submits when located in iframe set to display:none;");
|
||||
SimpleTest.finish();
|
||||
};
|
||||
|
||||
addLoadEvent(function() {
|
||||
connect("thebutton", "click", submitIframeForm);
|
||||
signal("thebutton", "click");
|
||||
});
|
||||
</script>
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user