test("append(String|Element|Array&lt;Element&gt;|jQuery)", function() { expect(18); var defaultText = 'Try them out:' var result = $('#first').append('<b>buga</b>'); ok( result.text() == defaultText + 'buga', 'Check if text appending works' ); ok( $('#select3').append('<option value="appendTest">Append Test</option>').find('option:last-child').attr('value') == 'appendTest', 'Appending html options to select element');  reset(); var expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:"; $('#sap').append(document.getElementById('first')); ok( expected == $('#sap').text(), "Check for appending of element" );  reset(); expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:Yahoo"; $('#sap').append([document.getElementById('first'), document.getElementById('yahoo')]); ok( expected == $('#sap').text(), "Check for appending of array of elements" );  reset(); expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:Yahoo"; $('#sap').append($("#first, #yahoo")); ok( expected == $('#sap').text(), "Check for appending of jQuery object" ); 
test("wrapInner(String|Element)", function() { expect(6); var num = $("#first").children().length; var result = $('#first').wrapInner('<div class="red"><div id="tmp"></div></div>'); equals( $("#first").children().length, 1, "Only one child" ); ok( $("#first").children().is(".red"), "Verify Right Element" ); equals( $("#first").children().children().children().length, num, "Verify Elements Intact" ); 
test("append(String|Element|Array&lt;Element&gt;|jQuery)", function() {	expect(18);	var defaultText = 'Try them out:'	var result = $('#first').append('<b>buga</b>');	ok( result.text() == defaultText + 'buga', 'Check if text appending works' );	ok( $('#select3').append('<option value="appendTest">Append Test</option>').find('option:last-child').attr('value') == 'appendTest', 'Appending html options to select element');		reset();	var expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:";	$('#sap').append(document.getElementById('first'));	ok( expected == $('#sap').text(), "Check for appending of element" );		reset();	expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:Yahoo";	$('#sap').append([document.getElementById('first'), document.getElementById('yahoo')]);	ok( expected == $('#sap').text(), "Check for appending of array of elements" );		reset();	expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:Yahoo";	$('#sap').append($("#first, #yahoo"));	ok( expected == $('#sap').text(), "Check for appending of jQuery object" );	reset();	$("#sap").append( 5 );	ok( $("#sap")[0].innerHTML.match( /5$/ ), "Check for appending a number" );	reset();	$("#sap").append( " text with spaces " );	ok( $("#sap")[0].innerHTML.match(/ text with spaces $/), "Check for appending text with spaces" );	reset();	ok( $("#sap").append([]), "Check for appending an empty array." );	ok( $("#sap").append(""), "Check for appending an empty string." );	ok( $("#sap").append(document.getElementsByTagName("foo")), "Check for appending an empty nodelist." );		reset();	$("#sap").append(document.getElementById('form'));	ok( $("#sap>form").size() == 1, "Check for appending a form" );  // Bug #910	reset();	var pass = true;	try {		$( $("iframe")[0].contentWindow.document.body ).append("<div>test</div>");	} catch(e) {		pass = false;	}	ok( pass, "Test for appending a DOM node to the contents of an IFrame" );		reset();	$('<fieldset/>').appendTo('#form').append('<legend id="legend">test</legend>');	t( 'Append legend', '#legend', ['legend'] );		reset();	$('#select1').append('<OPTION>Test</OPTION>');	ok( $('#select1 option:last').text() == "Test", "Appending &lt;OPTION&gt; (all caps)" );		$('#table').append('<colgroup></colgroup>');	ok( $('#table colgroup').length, "Append colgroup" );		$('#table colgroup').append('<col/>');	ok( $('#table colgroup col').length, "Append col" );		reset();	$('#table').append('<caption></caption>');	ok( $('#table caption').length, "Append caption" );	reset();	$('form:last')		.append('<select id="appendSelect1"></select>')		.append('<select id="appendSelect2"><option>Test</option></select>');		t( "Append Select", "#appendSelect1, #appendSelect2", ["appendSelect1", "appendSelect2"] );});
6056	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/6056/0a755f6ab38d36ffda02f9ff5a6d606c24a94baa/core.js/clean/test/unit/core.js