Commit c40c31a3 authored by Heinrich Fenkart's avatar Heinrich Fenkart
Browse files

Dropdown unit tests: Tiny style changes

parent 1d892cee
4 merge requests!28721Hot test,!16605Test pull please ignore,!22103test,!25326Adjust examples
Showing with 5 additions and 3 deletions
+5 -3
......@@ -58,12 +58,16 @@ $(function () {
+ '</ul>'
+ '</li>'
+ '</ul>'
var $dropdown = $(dropdownHTML).find('[data-toggle="dropdown"]').bootstrapDropdown().click()
var $dropdown = $(dropdownHTML)
.find('[data-toggle="dropdown"]')
.bootstrapDropdown()
.click()
assert.strictEqual($dropdown.attr('aria-expanded'), 'true', 'aria-expanded is set to string "true" on click')
})
QUnit.test('should set aria-expanded="false" on target when dropdown menu is hidden', function (assert) {
var done = assert.async()
var dropdownHTML = '<ul class="tabs">'
+ '<li class="dropdown">'
+ '<a href="#" class="dropdown-toggle" aria-expanded="false" data-toggle="dropdown">Dropdown</a>'
......@@ -80,8 +84,6 @@ $(function () {
.find('[data-toggle="dropdown"]')
.bootstrapDropdown()
var done = assert.async()
$dropdown
.parent('.dropdown')
.on('hidden.bs.dropdown', function () {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment