Skip to content

Commit

Permalink
Add mutation tests
Browse files Browse the repository at this point in the history
  • Loading branch information
JanAckermann committed Apr 21, 2022
1 parent bfe8b1b commit 542f573
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions packages/web-app-files/tests/unit/store/mutations.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,15 @@ describe('vuex store mutations', () => {
expect(state.areHiddenFilesShown).toEqual(false)
})

it('SET_FILE_EXTENSIONS_VISIBILITY', () => {
const state = { areFileExtensionsShown: true }
const { SET_FILE_EXTENSIONS_VISIBILITY } = mutations

SET_FILE_EXTENSIONS_VISIBILITY(state, false)

expect(state.areFileExtensionsShown).toEqual(false)
})

describe('CURRENT_FILE_OUTGOING_SHARES_REMOVE', () => {
it('removes an outgoing user share', () => {
const shareToRemove = { id: 1, shareType: ShareTypes.user.value }
Expand Down

0 comments on commit 542f573

Please sign in to comment.