Add attachment support to mock tests
This commit is contained in:
parent
6940c532ea
commit
9010245083
6 changed files with 252 additions and 11 deletions
|
@ -139,12 +139,14 @@ export function sendTextMessage({
|
|||
from,
|
||||
to,
|
||||
text,
|
||||
attachments,
|
||||
desktop,
|
||||
timestamp = Date.now(),
|
||||
}: {
|
||||
from: PrimaryDevice;
|
||||
to: PrimaryDevice | Device | GroupInfo;
|
||||
text: string;
|
||||
attachments?: Array<Proto.IAttachmentPointer>;
|
||||
desktop: Device;
|
||||
timestamp?: number;
|
||||
}): Promise<void> {
|
||||
|
@ -158,6 +160,7 @@ export function sendTextMessage({
|
|||
to: to as PrimaryDevice,
|
||||
dataMessage: {
|
||||
body: text,
|
||||
attachments,
|
||||
timestamp: Long.fromNumber(timestamp),
|
||||
groupV2: groupInfo
|
||||
? {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue