mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Initial attempt at spec for show/hide password
This commit is contained in:
parent
74b56cbca7
commit
0b03bf2fcc
@ -38,7 +38,7 @@ describe('LoginForm', () => {
|
||||
error: jest.fn(),
|
||||
},
|
||||
}
|
||||
return mount(LoginForm, { mocks, localVue, propsData, store })
|
||||
return mount(LoginForm, { mocks, localVue, propsData, store, data })
|
||||
}
|
||||
|
||||
describe('fill in email and password and submit', () => {
|
||||
@ -57,5 +57,13 @@ describe('LoginForm', () => {
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('Click event', () => {
|
||||
it('clicking icon shows/hides password and changes icon', () => {
|
||||
wrapper.find('a.click-wrapper').trigger('click')
|
||||
expect(wrapper.data.showPassword).toEqual(!showPassword)
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user