diff --git a/packages/backend/test/endpoints.ts b/packages/backend/test/endpoints.ts index 1331cf77c30bc4e66c7d5c459d78276d361dc51c..2aedc25f2ce83c1b3f31277029c07aae08063db0 100644 --- a/packages/backend/test/endpoints.ts +++ b/packages/backend/test/endpoints.ts @@ -223,10 +223,17 @@ describe('API: Endpoints', () => { const alice = await signup({ username: 'alice' }); const res = await request('/notes/reactions/create', { noteId: bobPost.id, - reaction: 'ðŸ‘', + reaction: '🚀', }, alice); assert.strictEqual(res.status, 204); + + const resNote = await request('/notes/show', { + noteId: bobPost.id, + }, alice); + + assert.strictEqual(resNote.status, 200); + assert.strictEqual(resNote.body.reactions['🚀'], [alice.id]); })); it('自分ã®æŠ•ç¨¿ã«ã‚‚リアクションã§ãã‚‹', async(async () => { @@ -234,7 +241,7 @@ describe('API: Endpoints', () => { const res = await request('/notes/reactions/create', { noteId: myPost.id, - reaction: 'ðŸ‘', + reaction: '🚀', }, alice); assert.strictEqual(res.status, 204); @@ -247,7 +254,7 @@ describe('API: Endpoints', () => { const res = await request('/notes/reactions/create', { noteId: bobPost.id, - reaction: 'ðŸ‘', + reaction: '🚀', }, alice); assert.strictEqual(res.status, 400); @@ -256,7 +263,7 @@ describe('API: Endpoints', () => { it('å˜åœ¨ã—ãªã„投稿ã«ã¯ãƒªã‚¢ã‚¯ã‚·ãƒ§ãƒ³ã§ããªã„', async(async () => { const res = await request('/notes/reactions/create', { noteId: '000000000000000000000000', - reaction: 'ðŸ‘', + reaction: '🚀', }, alice); assert.strictEqual(res.status, 400); @@ -271,7 +278,7 @@ describe('API: Endpoints', () => { it('é–“é•ã£ãŸIDã§æ€’られる', async(async () => { const res = await request('/notes/reactions/create', { noteId: 'kyoppie', - reaction: 'ðŸ‘', + reaction: '🚀', }, alice); assert.strictEqual(res.status, 400);