From e4cf21b2de23569edf96d3fcc5c055060209fb6e Mon Sep 17 00:00:00 2001 From: Vincent Date: Wed, 1 Jul 2020 12:34:51 +1000 Subject: [PATCH] ConversationAttributes typofix --- ts/test/session/utils/SyncMessage_test.ts | 14 ++++++++++++-- ts/test/test-utils/utils/message.ts | 9 +++++---- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/ts/test/session/utils/SyncMessage_test.ts b/ts/test/session/utils/SyncMessage_test.ts index dd71fbcd3..df14f6627 100644 --- a/ts/test/session/utils/SyncMessage_test.ts +++ b/ts/test/session/utils/SyncMessage_test.ts @@ -23,10 +23,20 @@ describe('Sync Message Utils', () => { const numConversations = 20; const primaryConversations = new Array(numConversations / 2) .fill({}) - .map(() => new TestUtils.MockConversation({ type: TestUtils.MockConversationType.Primary })); + .map( + () => + new TestUtils.MockConversation({ + type: TestUtils.MockConversationType.Primary, + }) + ); const secondaryConversations = new Array(numConversations / 2) .fill({}) - .map(() => new TestUtils.MockConversation({ type: TestUtils.MockConversationType.Secondary })); + .map( + () => + new TestUtils.MockConversation({ + type: TestUtils.MockConversationType.Secondary, + }) + ); const conversations = [...primaryConversations, ...secondaryConversations]; const sandbox = sinon.createSandbox(); diff --git a/ts/test/test-utils/utils/message.ts b/ts/test/test-utils/utils/message.ts index 1bd76bd32..4aef39cd0 100644 --- a/ts/test/test-utils/utils/message.ts +++ b/ts/test/test-utils/utils/message.ts @@ -6,7 +6,7 @@ import { import { v4 as uuid } from 'uuid'; import { OpenGroup } from '../../../session/types'; import { generateFakePubKey, generateFakePubKeys } from './pubkey'; -import { ConversationAttributes } from '../../../../js/models/conversation'; +import { ConversationAttributes } from '../../../../js/models/conversations'; export function generateChatMessage(identifier?: string): ChatMessage { return new ChatMessage({ @@ -73,9 +73,10 @@ export class MockConversation { this.id = params.id ?? generateFakePubKey().key; this.isPrimary = this.type === MockConversationType.Primary; - const members = this.type === MockConversationType.Group - ? params.members ?? generateFakePubKeys(10).map(m => m.key) - : []; + const members = + this.type === MockConversationType.Group + ? params.members ?? generateFakePubKeys(10).map(m => m.key) + : []; this.attributes = { members,