import { EventEmitter } from 'eventemitter3'; import type { Channel, Topic, Asset, Tag, Participant } from '../src/types'; export class MockStreamModule { public revision: number; private emitter: EventEmitter; constructor() { this.revision = 0; this.emitter = new EventEmitter(); } public close(): void { } public async setRevision(rev: number): Promise { this.revision = rev; } public addChannelListener(ev: (arg: { channels: Channel[], cardId: string | null }) => void): void { this.emitter.on('channel', ev); } public removeChannelListener(ev: (arg: { channels: Channel[], cardId: string | null }) => void): void { this.emitter.off('channel', ev); } public async setBlockedChannel(channelId: string, blocked: boolean): Promise { } public async getBlockedChannels(): Promise { return []; } public async flagChannel(channelId: string): Promise { } public async getChannelNotifications(channelId: string): Promise { return false; } public async setChannelNotifications(channelId: string, enabled: boolean): Promise { } public async addChannel(sealed: boolean, type: string, subject: string, cardIds: string[]): Promise { return ''; } public async removeChannel(channelId: string): Promise { } public async setChannelSubject(channelId: string, subject: string): Promise { } public async setChannelCard(channelId: string, cardId: string): Promise { } public async clearChannelCard(channelId: string, cardId: string): Promise { } public async setChannelGroup(channelId: string, groupId: string): Promise { } public async clearChannelGroup(channelId: string, groupId: string): Promise { } public async setUnreadChannel(channelId: string, unread: boolean): Promise { } }