Tests: further improvements QUnit 2.0 migration

* Remove QUnit jshint globals
* Extend QUnit.assert methods
* Use assert.async instead of start/stop/done

Ref b930d14ce6
Ref c8d15a2f9f
This commit is contained in:
Oleg Gaidarenko
2015-09-08 03:26:29 +03:00
parent f71e32d4b4
commit 2f0cedc997
16 changed files with 284 additions and 262 deletions

View File

@@ -91,7 +91,7 @@ QUnit.test( "show()", function( assert ) {
} );
// Tolerate data from show()/hide()
QUnit.expectJqData( this, div, "display" );
assert.expectJqData( this, div, "display" );
jQuery(
"<div id='show-tests'>" +
@@ -222,7 +222,7 @@ QUnit.test( "Persist correct display value", function( assert ) {
clock.tick( 300 );
QUnit.expectJqData( this, $span, "display" );
assert.expectJqData( this, $span, "display" );
} );
QUnit.test( "animate(Hash, Object, Function)", function( assert ) {
@@ -1141,7 +1141,7 @@ QUnit.test( "interrupt toggle", function( assert ) {
jQuery.data( this, "startVal", jQuery( this ).css( prop ) );
// Expect display data from our .hide() call below
QUnit.expectJqData( env, this, "display" );
assert.expectJqData( env, this, "display" );
} );
// Interrupt a hiding toggle