diff options
author | Oleg Gaidarenko <markelog@gmail.com> | 2015-09-08 03:26:29 +0300 |
---|---|---|
committer | Oleg Gaidarenko <markelog@gmail.com> | 2015-09-08 04:06:20 +0300 |
commit | c8d15a2f9f108e90d3651c31e4abf45415a30fde (patch) | |
tree | 695a8bf692b069ba41058195463fe3646be18542 /test/unit/deferred.js | |
parent | 3dd3d1357d027a487559516fcdd9064cc792edab (diff) | |
download | jquery-c8d15a2f9f108e90d3651c31e4abf45415a30fde.tar.gz jquery-c8d15a2f9f108e90d3651c31e4abf45415a30fde.zip |
Tests: further improvements QUnit 2.0 migration
* Remove QUnit jshint globals
* Extend QUnit.assert methods
* Use assert.async instead of start/stop/done
Ref b930d14ce64937e9478405eee2828d4da091d2cb
Diffstat (limited to 'test/unit/deferred.js')
-rw-r--r-- | test/unit/deferred.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/unit/deferred.js b/test/unit/deferred.js index 33b5b4f16..2277df190 100644 --- a/test/unit/deferred.js +++ b/test/unit/deferred.js @@ -505,12 +505,14 @@ QUnit.test( "[PIPE ONLY] jQuery.Deferred.pipe - context", function( assert ) { } ); } ); -QUnit.asyncTest( "jQuery.Deferred.then - spec compatibility", function( assert ) { +QUnit.test( "jQuery.Deferred.then - spec compatibility", function( assert ) { assert.expect( 1 ); + var done = assert.async(); + var defer = jQuery.Deferred().done( function() { - setTimeout( start ); + setTimeout( done ); throw new Error(); } ); |