aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/dialog/dialog_deprecated.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/dialog/dialog_deprecated.js')
-rw-r--r--tests/unit/dialog/dialog_deprecated.js15
1 files changed, 7 insertions, 8 deletions
diff --git a/tests/unit/dialog/dialog_deprecated.js b/tests/unit/dialog/dialog_deprecated.js
index 6a26c229e..55c180457 100644
--- a/tests/unit/dialog/dialog_deprecated.js
+++ b/tests/unit/dialog/dialog_deprecated.js
@@ -2,26 +2,25 @@
module( "dialog (deprecated): options" );
-test( "dialogClass", function() {
- expect( 6 );
+test( "dialogClass", function( assert ) {
+ expect( 5 );
var element = $( "<div>" ).dialog(),
widget = element.dialog( "widget" );
- equal( widget.is( ".foo" ), false, "dialogClass not specified. class not added" );
+ assert.lacksClasses( widget, "foo", "dialogClass not specified. class not added" );
element.remove();
element = $( "<div>" ).dialog({ dialogClass: "foo" });
widget = element.dialog( "widget" );
- equal( widget.is( ".foo" ), true, "dialogClass in init, foo class added" );
+ assert.hasClasses( widget, "foo", "dialogClass in init, foo class added" );
element.dialog( "option", "dialogClass", "foobar" );
- equal( widget.is( ".foo" ), false, "dialogClass changed, previous one was removed" );
- equal( widget.is( ".foobar" ), true, "dialogClass changed, new one was added" );
+ assert.lacksClasses( widget, "foo", "dialogClass changed, previous one was removed" );
+ assert.hasClasses( widget, "foobar", "dialogClass changed, new one was added" );
element.remove();
element = $( "<div>" ).dialog({ dialogClass: "foo bar" });
widget = element.dialog( "widget" );
- equal( widget.is( ".foo" ), true, "dialogClass in init, two classes. foo class added" );
- equal( widget.is( ".bar" ), true, "dialogClass in init, two classes. bar class added" );
+ assert.hasClasses( widget, "foo bar", "dialogClass in init, two classes." );
element.remove();
});