equal(result.text(),defaultText+"buga","Check if text appending works");
equal(result.text(),defaultText+"buga","Check if text appending works");
equal(jQuery("#select3").append(valueObj("<option value='appendTest'>Append Test</option>")).find("option:last-child").attr("value"),"appendTest","Appending html options to select element");
equal(jQuery("#select3").append(valueObj("<option value='appendTest'>Append Test</option>")).find("option:last-child").attr("value"),"appendTest","Appending html options to select element");
...
@@ -455,7 +457,7 @@ var testAppend = function(valueObj) {
...
@@ -455,7 +457,7 @@ var testAppend = function(valueObj) {
equal($radio[0].checked,true,"Reappending radios uphold which radio is checked");
equal($radio[0].checked,true,"Reappending radios uphold which radio is checked");
equal($radioNot[0].checked,false,"Reappending radios uphold not being checked");
equal($radioNot[0].checked,false,"Reappending radios uphold not being checked");
equal(jQuery("#first").text(),defaultText+"buga","Check if text appending works");
equal(jQuery("#first").text(),defaultText+"buga","Check if text appending works");
equal(jQuery("<option value='appendTest'>Append Test</option>").appendTo("#select3").parent().find("option:last-child").attr("value"),"appendTest","Appending html options to select element");
equal(jQuery("<option value='appendTest'>Append Test</option>").appendTo("#select3").parent().find("option:last-child").attr("value"),"appendTest","Appending html options to select element");
equal(result.text(),"buga"+defaultText,"Check if text prepending works");
equal(result.text(),"buga"+defaultText,"Check if text prepending works");
equal(jQuery("#select3").prepend(val("<option value='prependTest'>Prepend Test</option>")).find("option:first-child").attr("value"),"prependTest","Prepending html options to select element");
equal(jQuery("#select3").prepend(val("<option value='prependTest'>Prepend Test</option>")).find("option:first-child").attr("value"),"prependTest","Prepending html options to select element");
...
@@ -837,7 +841,7 @@ test("prepend(Function) with incoming value", function() {
...
@@ -837,7 +841,7 @@ test("prepend(Function) with incoming value", function() {
equal(jQuery("#first").text(),"buga"+defaultText,"Check if text prepending works");
equal(jQuery("#first").text(),"buga"+defaultText,"Check if text prepending works");
equal(jQuery("<option value='prependTest'>Prepend Test</option>").prependTo("#select3").parent().find("option:first-child").attr("value"),"prependTest","Prepending html options to select element");
equal(jQuery("<option value='prependTest'>Prepend Test</option>").prependTo("#select3").parent().find("option:first-child").attr("value"),"prependTest","Prepending html options to select element");
...
@@ -893,7 +897,7 @@ var testBefore = function(val) {
...
@@ -893,7 +897,7 @@ var testBefore = function(val) {
@@ -1352,7 +1358,9 @@ var testHtml = function(valueObj) {
...
@@ -1352,7 +1358,9 @@ var testHtml = function(valueObj) {
div.html(valueObj("<b>test</b>"));
div.html(valueObj("<b>test</b>"));
varpass=true;
varpass=true;
for(vari=0;i<div.size();i++){
for(vari=0;i<div.size();i++){
if(div.get(i).childNodes.length!=1)pass=false;
if(div.get(i).childNodes.length!=1){
pass=false;
}
}
}
ok(pass,"Set HTML");
ok(pass,"Set HTML");
...
@@ -1416,7 +1424,7 @@ var testHtml = function(valueObj) {
...
@@ -1416,7 +1424,7 @@ var testHtml = function(valueObj) {
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("#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("#qunit-fixture").html(valueObj("<script>equal(jQuery.scriptorder++, 0, 'Script is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html (even though appears before)')<\/script><span id='scriptorder'><script>equal(jQuery.scriptorder++, 1, 'Script (nested) is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html')<\/script></span><script>equal(jQuery.scriptorder++, 2, 'Script (unnested) is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html')<\/script>"));
jQuery("#qunit-fixture").html(valueObj("<script>equal(jQuery.scriptorder++, 0, 'Script is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html (even though appears before)')<\/script><span id='scriptorder'><script>equal(jQuery.scriptorder++, 1, 'Script (nested) is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html')<\/script></span><script>equal(jQuery.scriptorder++, 2, 'Script (unnested) is executed in order');equal(jQuery('#scriptorder').length, 1,'Execute after html')<\/script>"));
deepEqual(jQuery("p",jQuery("div")).get(),q("firstp","ap","sndp","en","sap","first"),"Finding elements with a context.");
deepEqual(jQuery("p",jQuery("div")).get(),q("firstp","ap","sndp","en","sap","first"),"Finding elements with a context.");
deepEqual(jQuery("div").find("p").get(),q("firstp","ap","sndp","en","sap","first"),"Finding elements with a context.");
deepEqual(jQuery("div").find("p").get(),q("firstp","ap","sndp","en","sap","first"),"Finding elements with a context.");
ok(jQuery("#length").length,"\<input name=\"length\"\> cannot be found under IE, see #945");
ok(jQuery("#length").length,"<input name=\"length\"> cannot be found under IE, see #945");
ok(jQuery("#lengthtest input").length,"\<input name=\"length\"\> cannot be found under IE, see #945");
ok(jQuery("#lengthtest input").length,"<input name=\"length\"> cannot be found under IE, see #945");
//#7533
//#7533
equal(jQuery("<div id=\"A'B~C.D[E]\"><p>foo</p></div>").find("p").length,1,"Find where context root is a node and has an ID with CSS3 meta characters");
equal(jQuery("<div id=\"A'B~C.D[E]\"><p>foo</p></div>").find("p").length,1,"Find where context root is a node and has an ID with CSS3 meta characters");