(event: Event, metadata: { expires_at?: number; deleted_at?: Date | null } = {})
| 20 | const { expect } = chai |
| 21 | |
| 22 | const toDbEvent = (event: Event, metadata: { expires_at?: number; deleted_at?: Date | null } = {}) => ({ |
| 23 | event_id: Buffer.from(event.id, 'hex'), |
| 24 | event_kind: event.kind, |
| 25 | event_pubkey: Buffer.from(event.pubkey, 'hex'), |
| 26 | event_created_at: event.created_at, |
| 27 | event_content: event.content, |
| 28 | event_tags: event.tags, |
| 29 | event_signature: Buffer.from(event.sig, 'hex'), |
| 30 | ...metadata, |
| 31 | }) |
| 32 | |
| 33 | describe('SubscribeMessageHandler', () => { |
| 34 | const subscriptionId: SubscriptionId = 'subscriptionId' |
no outgoing calls
no test coverage detected