mirror of
https://github.com/twbs/bootstrap.git
synced 2022-11-09 12:25:43 -05:00
Swapped out .hasClass() with .is() when checking for multiple classes
This commit is contained in:
parent
e388a5e475
commit
8dda83906d
1 changed files with 7 additions and 7 deletions
14
js/tests/unit/bootstrap-tooltip.js
vendored
14
js/tests/unit/bootstrap-tooltip.js
vendored
|
@ -33,7 +33,7 @@ $(function () {
|
||||||
.tooltip({placement: 'bottom'})
|
.tooltip({placement: 'bottom'})
|
||||||
.tooltip('show')
|
.tooltip('show')
|
||||||
|
|
||||||
ok($(".tooltip").hasClass('fade bottom in'), 'has correct classes applied')
|
ok($(".tooltip").is('.fade.bottom.in'), 'has correct classes applied')
|
||||||
tooltip.tooltip('hide')
|
tooltip.tooltip('hide')
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -69,10 +69,10 @@ $(function () {
|
||||||
tooltip.trigger('mouseenter')
|
tooltip.trigger('mouseenter')
|
||||||
|
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip is not faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip is not faded in')
|
||||||
tooltip.trigger('mouseout')
|
tooltip.trigger('mouseout')
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip is not faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip is not faded in')
|
||||||
start()
|
start()
|
||||||
}, 200)
|
}, 200)
|
||||||
}, 100)
|
}, 100)
|
||||||
|
@ -104,10 +104,10 @@ $(function () {
|
||||||
stop()
|
stop()
|
||||||
tooltip.trigger('mouseenter')
|
tooltip.trigger('mouseenter')
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip is not faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip is not faded in')
|
||||||
tooltip.trigger('mouseout')
|
tooltip.trigger('mouseout')
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip is not faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip is not faded in')
|
||||||
start()
|
start()
|
||||||
}, 100)
|
}, 100)
|
||||||
}, 50)
|
}, 50)
|
||||||
|
@ -120,9 +120,9 @@ $(function () {
|
||||||
stop()
|
stop()
|
||||||
tooltip.trigger('mouseenter')
|
tooltip.trigger('mouseenter')
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip is not faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip is not faded in')
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
ok(!$(".tooltip").hasClass('fade in'), 'tooltip has faded in')
|
ok(!$(".tooltip").is('.fade.in'), 'tooltip has faded in')
|
||||||
start()
|
start()
|
||||||
}, 200)
|
}, 200)
|
||||||
}, 100)
|
}, 100)
|
||||||
|
|
Loading…
Add table
Reference in a new issue