fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] changelog2011-02-28 01:15 pm

[dw-free] Make libfunctions > jquery test complete in IE

[commit: http://hg.dwscoalition.org/dw-free/rev/0dc6fb714407]

http://bugs.dwscoalition.org/show_bug.cgi?id=3545

Move array.forEach to be old library-specific, and use $.each for jQuery
libs.

Patch by [personal profile] fu.

Files modified:
  • views/dev/tests/libfunctions.js
--------------------------------------------------------------------------------
diff -r f28611519cb3 -r 0dc6fb714407 views/dev/tests/libfunctions.js
--- a/views/dev/tests/libfunctions.js	Mon Feb 28 20:31:11 2011 +0800
+++ b/views/dev/tests/libfunctions.js	Mon Feb 28 21:15:17 2011 +0800
@@ -159,7 +159,6 @@ test( "Check all", function() {
     ok( o, "CheckallButton" );
 });
 
-module( "*libfunctions" );
 test( "array tests", function () {
     expect(4);
 
@@ -175,6 +174,23 @@ test( "array tests", function () {
     });
 });
 
+module( "jquery" );
+test( "array tests", function () {
+    expect(4);
+
+    var array = new Array();
+    array.push( "a" );
+    array.push( "b" );
+    array.push( "c" );
+
+    equals( 3, array.length, "Check array size" );
+
+    $.each( array, function(index, element) {
+        equals( element, array[index] );
+    });
+});
+
+module( "*libfunctions" );
 test("object tests", function() {
     // expect(1);
 
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org