From d513fec7fe4f4e74ad4a5ec8e8ee26f4c906e51b Mon Sep 17 00:00:00 2001 From: Hannes Heine Date: Thu, 6 Aug 2020 16:12:36 +0200 Subject: [PATCH] Added test comment that is disabled and changes the test name so that we see that the test checks the comment count to ignore disabled and deleted comments. --- webapp/components/CommentList/CommentList.spec.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/webapp/components/CommentList/CommentList.spec.js b/webapp/components/CommentList/CommentList.spec.js index 4deee4180..d0d54aa68 100644 --- a/webapp/components/CommentList/CommentList.spec.js +++ b/webapp/components/CommentList/CommentList.spec.js @@ -35,6 +35,13 @@ describe('CommentList.vue', () => { deleted: true, author: { id: 'some-user' }, }, + { + id: 'comment136', + contentExcerpt: 'this is a disabled comment', + content: 'this is a disabled comment', + disabled: true, + author: { id: 'some-user' }, + }, ], }, } @@ -77,7 +84,7 @@ describe('CommentList.vue', () => { }) } - it('displays a comments counter', () => { + it('displays a comments counter that ignores disabled and deleted comments', () => { wrapper = Wrapper() expect(wrapper.find('.count').text()).toEqual('1') })