QUnit: fix swapped expected/actual fields
authorDerk-Jan Hartman <hartman.wiki@gmail.com>
Wed, 6 Aug 2014 15:50:28 +0000 (16:50 +0100)
committerDerk-Jan Hartman <hartman.wiki@gmail.com>
Wed, 6 Aug 2014 16:03:19 +0000 (17:03 +0100)
Change-Id: I55db7e3ef4e155fb9e1152cbf777189d04eec951

tests/qunit/suites/resources/jquery/jquery.tablesorter.test.js

index 9216ac9..2fd3ce9 100644 (file)
                                '</table>'
                );
                $table.tablesorter();
-               assert.equal( 0,
-                       $table.find( '#A2' ).prop( 'headerIndex' ),
-                       'A2 should be a sort header'
+               assert.equal( $table.find( '#A2' ).prop( 'headerIndex' ),
+                       0,
+                       'A2 should not be a sort header'
                );
-               assert.equal( 1, // should be 2
-                       $table.find( '#C1' ).prop( 'headerIndex' ),
+               assert.equal( $table.find( '#C1' ).prop( 'headerIndex' ),
+                       1,
                        'C1 should be a sort header, but will sort the wrong column'
                );
        } );
                        '</tbody></table>' );
 
                        $table.tablesorter();
-                       assert.equal( 2, $table.find( 'tr:eq(1) th:eq(1)').prop('headerIndex'), 'Incorrect index of sort header' );
+                       assert.equal( $table.find( 'tr:eq(1) th:eq(1)').prop('headerIndex'),
+                               2,
+                               'Incorrect index of sort header' );
                }
        );