X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fjquery%2FcoreTest.js;h=37fe73b75b0f74464f3cb8915737bf58cff6c581;hb=8b683b891f2cfd299c1d0708bb41ea26393ea417;hp=9791767089cf42fd76022981933c016b442f5d04;hpb=958bed09da67c052dfa85c0bb8c0dc88873e5923;p=jquery.git
diff --git a/src/jquery/coreTest.js b/src/jquery/coreTest.js
index 9791767..37fe73b 100644
--- a/src/jquery/coreTest.js
+++ b/src/jquery/coreTest.js
@@ -225,7 +225,7 @@ test("attr(Hash)", function() {
});
test("attr(String, Object)", function() {
- expect(7);
+ expect(8);
var div = $("div");
div.attr("foo", "bar");
var pass = true;
@@ -246,6 +246,8 @@ test("attr(String, Object)", function() {
ok( document.getElementById('text1').readOnly == true, 'Set readonly attribute' );
$("#text1").attr('readonly', false);
ok( document.getElementById('text1').readOnly == false, 'Set readonly attribute' );
+ $("#name").attr('maxlength', '5');
+ ok( document.getElementById('name').maxLength == '5', 'Set maxlength attribute' );
});
if ( location.protocol != "file:" ) {
@@ -356,14 +358,14 @@ test("wrap(String|Element)", function() {
});
test("append(String|Element|Array<Element>|jQuery)", function() {
- expect(14);
+ expect(17);
var defaultText = 'Try them out:'
var result = $('#first').append('buga');
ok( result.text() == defaultText + 'buga', 'Check if text appending works' );
ok( $('#select3').append('').find('option:last-child').attr('value') == 'appendTest', 'Appending html options to select element');
reset();
- expected = "This link has class=\"blog\": Simon Willison's WeblogTry them out:";
+ 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" );
@@ -405,24 +407,36 @@ test("append(String|Element|Array<Element>|jQuery)", function() {
ok( pass, "Test for appending a DOM node to the contents of an IFrame" );
reset();
- $('#select1').appendTo('#foo');
- t( 'Append select', '#foo select', ['select1'] );
-
- reset();
$('