mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Fix tests in 'AvatarUploader.spec.js'
This commit is contained in:
parent
6f6dc4e7fd
commit
8da2d1102f
@ -29,6 +29,7 @@ describe('AvatarUploader', () => {
|
|||||||
profile: {
|
profile: {
|
||||||
avatar: { url: '/api/generic.jpg' },
|
avatar: { url: '/api/generic.jpg' },
|
||||||
},
|
},
|
||||||
|
updateMutation: jest.fn(),
|
||||||
}
|
}
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
@ -40,7 +41,7 @@ describe('AvatarUploader', () => {
|
|||||||
jest.clearAllMocks()
|
jest.clearAllMocks()
|
||||||
})
|
})
|
||||||
|
|
||||||
it('sends a the UpdateUser mutation when vddrop is called', () => {
|
it('sends the UpdateUser mutation when vddrop is called', () => {
|
||||||
wrapper.vm.vddrop([{ filename: 'avatar.jpg' }])
|
wrapper.vm.vddrop([{ filename: 'avatar.jpg' }])
|
||||||
expect(mocks.$apollo.mutate).toHaveBeenCalledTimes(1)
|
expect(mocks.$apollo.mutate).toHaveBeenCalledTimes(1)
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user