cic-internal-integration/apps/cic-meta/tests/3_transport.ts

15 lines
315 B
TypeScript
Raw Permalink Normal View History

2021-02-08 18:31:29 +01:00
import * as assert from 'assert';
import { MockPubSub, MockConsumer } from './mock';
describe('transport', () => {
it('pub_sub', () => {
const c = new MockConsumer();
const ps = new MockPubSub('foo', c);
ps.pub('foo');
ps.pub('bar');
ps.flush();
assert.deepEqual(c.omnoms, ['foo', 'bar']);
});
});