Skip to content

Commit e693d4b

Browse files
authored
Update dropdown-form.spec.js
1 parent bf502c3 commit e693d4b

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/components/dropdown/dropdown-form.spec.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,16 @@ describe('dropdown-form', () => {
1010
expect(form.is('form')).toBe(true)
1111
})
1212

13+
it('has tabindex on form', async () => {
14+
const wrapper = mount(BDropdownForm)
15+
expect(wrapper.is('li')).toBe(true)
16+
17+
const form = wrapper.find('form')
18+
expect(form.is('form')).toBe(true)
19+
expect(form.attributes('tabindex')).toBeDefined()
20+
expect(form.attributes('tabindex')).toEqual('0')
21+
})
22+
1323
it('has custom class "b-dropdown-form"', async () => {
1424
const wrapper = mount(BDropdownForm)
1525
expect(wrapper.is('li')).toBe(true)
@@ -29,6 +39,7 @@ describe('dropdown-form', () => {
2939
const form = wrapper.find('form')
3040
expect(form.classes()).toContain('was-validated')
3141
expect(form.classes()).toContain('b-dropdown-form')
42+
expect(form.classes()).toContain('dropdown-item')
3243
})
3344

3445
it('does not have attribute novalidate by default', async () => {

0 commit comments

Comments
 (0)