From f31f986d669e5f20de1f949331a5f06ad3359654 Mon Sep 17 00:00:00 2001 From: syuilo Date: Tue, 23 Apr 2019 02:50:59 +0900 Subject: Fix #4768 --- test/streaming.ts | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'test') diff --git a/test/streaming.ts b/test/streaming.ts index 2dfede1380..6b9ef9cea5 100644 --- a/test/streaming.ts +++ b/test/streaming.ts @@ -594,6 +594,31 @@ describe('Streaming', () => { text: 'foo' }); })); + + it('ホーム投稿は流れない', () => new Promise(async done => { + const alice = await signup({ username: 'alice' }); + const bob = await signup({ username: 'bob' }); + + let fired = false; + + const ws = await connectStream(alice, 'globalTimeline', ({ type, body }) => { + if (type == 'note') { + fired = true; + } + }); + + // ホーム投稿 + post(bob, { + text: 'foo', + visibility: 'home' + }); + + setTimeout(() => { + assert.strictEqual(fired, false); + ws.close(); + done(); + }, 3000); + })); }); describe('UserList Timeline', () => { -- cgit v1.2.3-freya