mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-12-23 01:24:22 +00:00
9dc2bf9737
Some tests were not properly destroying tooltips which made tests start to fail with the new QUnit. Ref gh-2157
24 lines
523 B
JavaScript
24 lines
523 B
JavaScript
define( [
|
|
"qunit",
|
|
"jquery",
|
|
"./helper",
|
|
"ui/widgets/tooltip"
|
|
], function( QUnit, $, testHelper ) {
|
|
"use strict";
|
|
|
|
var beforeAfterEach = testHelper.beforeAfterEach;
|
|
|
|
QUnit.module( "tooltip: (deprecated) options", beforeAfterEach() );
|
|
|
|
QUnit.test( "tooltipClass", function( assert ) {
|
|
assert.expect( 1 );
|
|
var element = $( "#tooltipped1" ).tooltip( {
|
|
tooltipClass: "custom"
|
|
} ).tooltip( "open" );
|
|
assert.hasClasses( $( "#" + element.data( "ui-tooltip-id" ) ), "custom" );
|
|
|
|
element.tooltip( "destroy" );
|
|
} );
|
|
|
|
} );
|