Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Bootstrap
bootstrap
Commits
c40c31a3
Commit
c40c31a3
authored
10 years ago
by
Heinrich Fenkart
Browse files
Options
Download
Email Patches
Plain Diff
Dropdown unit tests: Tiny style changes
parent
1d892cee
4 merge requests
!28721
Hot test
,
!16605
Test pull please ignore
,
!22103
test
,
!25326
Adjust examples
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
js/tests/unit/dropdown.js
+5
-3
js/tests/unit/dropdown.js
with
5 additions
and
3 deletions
+5
-3
js/tests/unit/dropdown.js
+
5
-
3
View file @
c40c31a3
...
...
@@ -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
()
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets