]> source.dussan.org Git - jquery.git/commitdiff
Tests: Really fix tests in IE 8 this time
authorMichał Gołębiowski <m.goleb@gmail.com>
Tue, 8 Sep 2015 16:57:39 +0000 (18:57 +0200)
committerMichał Gołębiowski <m.goleb@gmail.com>
Tue, 8 Sep 2015 17:02:35 +0000 (19:02 +0200)
IE 8 doesn't have indexOf on arrays. Also, one toLowerCase() was missing. Oops.

This commit is not necessary on master but has been brought here to keep
tests similar in both branches.

(cherry-picked from 1b48eef4caf7fa3aba0ee1a3473e0d46487d20ea)

test/data/testinit.js
test/unit/basic.js

index d9cf8a2ebe042642ebc2707b759b18b689a834b3..fb99badfc2b0ded04df0cefc0648e15acaf17d06 100644 (file)
@@ -271,7 +271,7 @@ QUnit.config.autostart = false;
 this.loadTests = function() {
        var loadSwarm,
                url = window.location.search,
-               basicTests = url.substring( 1 ).split( "&" ).indexOf( "module=basic" ) > -1;
+               basicTests = jQuery.inArray( "module=basic", url.substring( 1 ).split( "&" ) ) > -1;
 
        url = decodeURIComponent( url.slice( url.indexOf( "swarmURL=" ) + "swarmURL=".length ) );
        loadSwarm = url && url.indexOf( "http" ) === 0;
index b1b9205ce038db5a39fd693ddde20afc217b8453..25e86d1a354255c45e1ad9c9f8f6be5ea818b84f 100644 (file)
@@ -200,7 +200,7 @@ QUnit.test( "manipulation", function( assert ) {
 
                // Support: IE 8 only
                // IE 8 prints tag names in upper case.
-               elem1.html(),
+               elem1.html().toLowerCase(),
                "<div></div><b></b><span></span><a></a>",
                ".after/.before"
        );