mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
Use jest's expectation matchers if possible
@Tirokk jest has a lot of assertion matchers that will give you better error messages than the default ones: https://jestjs.io/docs/en/expect.html#tohavelengthnumber
This commit is contained in:
parent
a978591843
commit
9384f85ebf
@ -66,7 +66,7 @@ describe('ProfileSlug', () => {
|
||||
beforeEach(jest.runAllTimers)
|
||||
|
||||
it('emits "deletePost"', () => {
|
||||
expect(wrapper.emitted().deletePost.length).toBe(1)
|
||||
expect(wrapper.emitted().deletePost).toHaveLength(1)
|
||||
})
|
||||
|
||||
it('does not go to index (main) page', () => {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user