mirror of
https://github.com/aljazceru/ditto.git
synced 2025-12-27 18:24:27 +01:00
8 lines
308 B
TypeScript
8 lines
308 B
TypeScript
import { NostrEvent } from '@nostrify/nostrify';
|
|
|
|
/** Import an event fixture by name in tests. */
|
|
export async function eventFixture(name: string): Promise<NostrEvent> {
|
|
const result = await import(`~/fixtures/events/${name}.json`, { with: { type: 'json' } });
|
|
return structuredClone(result.default);
|
|
}
|