Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/MessagesList/MessagesGroup/Message/Message.spec.js')
-rw-r--r--src/components/MessagesList/MessagesGroup/Message/Message.spec.js14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/components/MessagesList/MessagesGroup/Message/Message.spec.js b/src/components/MessagesList/MessagesGroup/Message/Message.spec.js
index a12c40f26..0bf661642 100644
--- a/src/components/MessagesList/MessagesGroup/Message/Message.spec.js
+++ b/src/components/MessagesList/MessagesGroup/Message/Message.spec.js
@@ -809,8 +809,10 @@ describe('Message.vue', () => {
test('dispatches store action upon picking an emoji from the emojipicker', () => {
const addReactionToMessageAction = jest.fn()
const userHasReactedGetter = jest.fn().mockReturnValue(() => false)
+ const reactionsLoadedGetter = jest.fn().mockReturnValue(() => true)
testStoreConfig.modules.quoteReplyStore.actions.addReactionToMessage = addReactionToMessageAction
testStoreConfig.modules.messagesStore.getters.userHasReacted = userHasReactedGetter
+ testStoreConfig.modules.messagesStore.getters.reactionsLoaded = reactionsLoadedGetter
store = new Store(testStoreConfig)
@@ -821,11 +823,6 @@ describe('Message.vue', () => {
stubs: {
EmojiPicker,
},
- data() {
- return {
- detailedReactionsRequested: true,
- }
- },
})
const emojiPicker = wrapper.findComponent(EmojiPicker)
@@ -844,8 +841,10 @@ describe('Message.vue', () => {
test('dispatches store action to remove an emoji upon clicking reaction button', async () => {
const removeReactionFromMessageAction = jest.fn()
const userHasReactedGetter = jest.fn().mockReturnValue(() => true)
+ const reactionsLoadedGetter = jest.fn().mockReturnValue(() => true)
testStoreConfig.modules.quoteReplyStore.actions.removeReactionFromMessage = removeReactionFromMessageAction
testStoreConfig.modules.messagesStore.getters.userHasReacted = userHasReactedGetter
+ testStoreConfig.modules.messagesStore.getters.reactionsLoaded = reactionsLoadedGetter
store = new Store(testStoreConfig)
@@ -853,11 +852,6 @@ describe('Message.vue', () => {
localVue,
store,
propsData: messageProps,
- data() {
- return {
- detailedReactionsRequested: true,
- }
- },
})
// Click reaction button upon having already reacted