Ghost/ghost/post-events/test/post-events.test.ts
Naz ffa101b550 Added post events package
refs https://github.com/TryGhost/Arch/issues/16

- This package is meant to hold Domain Events associated with Post model/entity. The very first one here is PostsBulkDestroyedEvent needed to signal bulk destroy action completion from the posts service.
2023-08-01 15:11:00 +08:00

11 lines
339 B
TypeScript

import assert from 'assert/strict';
import {PostsBulkDestroyedEvent} from '../src/index';
describe('Post Events', function () {
it('Can instantiate BulkDestroyEvent', function () {
const event = PostsBulkDestroyedEvent.create(['1', '2', '3']);
assert.ok(event);
assert.equal(event.data.length, 3);
});
});