diff options
author | Timo Tijhof <krinklemail@gmail.com> | 2012-11-25 20:30:16 +0100 |
---|---|---|
committer | Richard Gibson <richard.gibson@gmail.com> | 2012-12-06 13:46:37 -0500 |
commit | 5dd8a90f734297d51ef74a6c4be23c2a4e43c4df (patch) | |
tree | a48254b428fdeab0c15bdfc1233c5745c26cc6b2 /test/data | |
parent | 26bf8dd56bfbef54a07cbba519485dcd59add839 (diff) | |
download | jquery-5dd8a90f734297d51ef74a6c4be23c2a4e43c4df.tar.gz jquery-5dd8a90f734297d51ef74a6c4be23c2a4e43c4df.zip |
Make compatible with jshint, lint test/data. Close gh-1043.
Diffstat (limited to 'test/data')
-rw-r--r-- | test/data/test.js | 2 | ||||
-rw-r--r-- | test/data/testinit.js | 4 | ||||
-rw-r--r-- | test/data/testrunner.js | 14 |
3 files changed, 10 insertions, 10 deletions
diff --git a/test/data/test.js b/test/data/test.js index a18815315..5980bff91 100644 --- a/test/data/test.js +++ b/test/data/test.js @@ -1,3 +1,3 @@ var testBar = "bar"; -jQuery('#ap').html('bar'); +jQuery("#ap").html("bar"); ok( true, "test.js executed"); diff --git a/test/data/testinit.js b/test/data/testinit.js index bff6b8dff..ea940cb63 100644 --- a/test/data/testinit.js +++ b/test/data/testinit.js @@ -1,4 +1,4 @@ -/*jshint multistr:true */ +/*jshint multistr:true, quotmark:false */ var amdDefined, fireNative, originaljQuery = this.jQuery || "jQuery", @@ -207,7 +207,7 @@ function ajaxTest( title, expect, options ) { } }; }); -}; +} (function () { diff --git a/test/data/testrunner.js b/test/data/testrunner.js index ba6b892e3..c9888c383 100644 --- a/test/data/testrunner.js +++ b/test/data/testrunner.js @@ -232,7 +232,7 @@ var Globals = (function() { // Since this method was called it means some data was // expected to be found, but since there is nothing, fail early // (instead of in teardown). - notStrictEqual( expando, undefined, 'Target for expectJqData must have an expando, for else there can be no data to expect.' ); + notStrictEqual( expando, undefined, "Target for expectJqData must have an expando, for else there can be no data to expect." ); } else { if ( expectedDataKeys[expando] ) { expectedDataKeys[expando].push( key ); @@ -243,9 +243,9 @@ var Globals = (function() { } }; QUnit.config.urlConfig.push( { - id: 'jqdata', - label: 'Always check jQuery.data', - tooltip: 'Trigger "QUnit.expectJqData" detection for all tests instead of just the ones that call it' + id: "jqdata", + label: "Always check jQuery.data", + tooltip: "Trigger QUnit.expectJqData detection for all tests instead of just the ones that call it" } ); /** @@ -265,14 +265,14 @@ var Globals = (function() { expectedKeys = expectedDataKeys[i]; actualKeys = jQuery.cache[i] ? keys( jQuery.cache[i] ) : jQuery.cache[i]; if ( !QUnit.equiv( expectedKeys, actualKeys ) ) { - deepEqual( actualKeys, expectedKeys, 'Expected keys exist in jQuery.cache' ); + deepEqual( actualKeys, expectedKeys, "Expected keys exist in jQuery.cache" ); } delete jQuery.cache[i]; delete expectedDataKeys[i]; } // In case it was removed from cache before (or never there in the first place) for ( i in expectedDataKeys ) { - deepEqual( expectedDataKeys[i], undefined, 'No unexpected keys were left in jQuery.cache (#' + i + ')' ); + deepEqual( expectedDataKeys[i], undefined, "No unexpected keys were left in jQuery.cache (#" + i + ")" ); delete expectedDataKeys[i]; } } @@ -359,5 +359,5 @@ QUnit.config.requireExpects = true; return; } - document.write("<scr" + "ipt src='http://swarm.jquery.org/js/inject.js?" + (new Date).getTime() + "'></scr" + "ipt>"); + document.write("<scr" + "ipt src='http://swarm.jquery.org/js/inject.js?" + (new Date()).getTime() + "'></scr" + "ipt>"); })(); |