<!-- this iframe is outside the #main so it won't reload constantly wasting time, but it means the tests must be "safe" and clean up after themselves -->
<!-- this iframe is outside the #qunit-fixture so it won't reload constantly wasting time, but it means the tests must be "safe" and clean up after themselves -->
<pid="firstp">See <aid="simon1"href="http://simon.incutio.com/archive/2003/03/25/#getElementsBySelector"rel="bookmark">this blog entry</a> for more information.</p>
<pid="firstp">See <aid="simon1"href="http://simon.incutio.com/archive/2003/03/25/#getElementsBySelector"rel="bookmark">this blog entry</a> for more information.</p>
<pid="ap">
<pid="ap">
Here are some links in a normal paragraph: <aid="google"href="http://www.google.com/"title="Google!">Google</a>,
Here are some links in a normal paragraph: <aid="google"href="http://www.google.com/"title="Google!">Google</a>,
equals($div.html(valueObj(5)).html(),"5","Setting a number as html");
equals($div.html(valueObj(5)).html(),"5","Setting a number as html");
...
@@ -1113,23 +1113,23 @@ var testHtml = function(valueObj) {
...
@@ -1113,23 +1113,23 @@ var testHtml = function(valueObj) {
QUnit.reset();
QUnit.reset();
jQuery("#main").html(valueObj("<script type='something/else'>ok( false, 'Non-script evaluated.' );</script><script type='text/javascript'>ok( true, 'text/javascript is evaluated.' );</script><script>ok( true, 'No type is evaluated.' );</script><div><script type='text/javascript'>ok( true, 'Inner text/javascript is evaluated.' );</script><script>ok( true, 'Inner No type is evaluated.' );</script><script type='something/else'>ok( false, 'Non-script evaluated.' );</script></div>"));
jQuery("#qunit-fixture").html(valueObj("<script type='something/else'>ok( false, 'Non-script evaluated.' );</script><script type='text/javascript'>ok( true, 'text/javascript is evaluated.' );</script><script>ok( true, 'No type is evaluated.' );</script><div><script type='text/javascript'>ok( true, 'Inner text/javascript is evaluated.' );</script><script>ok( true, 'Inner No type is evaluated.' );</script><script type='something/else'>ok( false, 'Non-script evaluated.' );</script></div>"));
varchild=jQuery("#main").find("script");
varchild=jQuery("#qunit-fixture").find("script");
equals(child.length,2,"Make sure that two non-JavaScript script tags are left.");
equals(child.length,2,"Make sure that two non-JavaScript script tags are left.");
equals(child[0].type,"something/else","Verify type of script tag.");
equals(child[0].type,"something/else","Verify type of script tag.");
equals(child[1].type,"something/else","Verify type of script tag.");
equals(child[1].type,"something/else","Verify type of script tag.");
jQuery("#main").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#qunit-fixture").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#main").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#qunit-fixture").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#main").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#qunit-fixture").html(valueObj("<script>ok( true, 'Test repeated injection of script.' );</script>"));
jQuery("#main").html(valueObj("<script type='text/javascript'>ok( true, 'jQuery().html().evalScripts() Evals Scripts Twice in Firefox, see #975 (1)' );</script>"));
jQuery("#qunit-fixture").html(valueObj("<script type='text/javascript'>ok( true, 'jQuery().html().evalScripts() Evals Scripts Twice in Firefox, see #975 (1)' );</script>"));
jQuery("#main").html(valueObj("foo <form><script type='text/javascript'>ok( true, 'jQuery().html().evalScripts() Evals Scripts Twice in Firefox, see #975 (2)' );</script></form>"));
jQuery("#qunit-fixture").html(valueObj("foo <form><script type='text/javascript'>ok( true, 'jQuery().html().evalScripts() Evals Scripts Twice in Firefox, see #975 (2)' );</script></form>"));
jQuery("#main").html(valueObj("<script>equals(jQuery.scriptorder++, 0, 'Script is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html (even though appears before)')<\/script><span id='scriptorder'><script>equals(jQuery.scriptorder++, 1, 'Script (nested) is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html')<\/script></span><script>equals(jQuery.scriptorder++, 2, 'Script (unnested) is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html')<\/script>"));
jQuery("#qunit-fixture").html(valueObj("<script>equals(jQuery.scriptorder++, 0, 'Script is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html (even though appears before)')<\/script><span id='scriptorder'><script>equals(jQuery.scriptorder++, 1, 'Script (nested) is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html')<\/script></span><script>equals(jQuery.scriptorder++, 2, 'Script (unnested) is executed in order');equals(jQuery('#scriptorder').length, 1,'Execute after html')<\/script>"));