From 8ae7249a5bb12f23d402f0ede32956827de4e111 Mon Sep 17 00:00:00 2001 From: Ruben Beltran del Rio Date: Thu, 22 Apr 2021 00:18:28 +0200 Subject: Add blink test + coverage improvements --- src/components/error_block/error_block.test.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/components/error_block/error_block.test.js') diff --git a/src/components/error_block/error_block.test.js b/src/components/error_block/error_block.test.js index 1d7a7ac..43c9331 100644 --- a/src/components/error_block/error_block.test.js +++ b/src/components/error_block/error_block.test.js @@ -7,7 +7,7 @@ import ErrorBlock from './error_block.svelte'; describe('Error Block component', () => { - test('Should act as an image', () => { + test('Should display error message sent', () => { const results = render(ErrorBlock, { props: { message: 'An error has, sadly, destroyed everything.' @@ -16,5 +16,13 @@ describe('Error Block component', () => { expect(results.getByText('An error has, sadly, destroyed everything.')) .toBeVisible(); }); + + test('Should display default error message', () => { + + const results = render(ErrorBlock); + + expect(results.getByText('Unknown error has occurred. Panic!')) + .toBeVisible(); + }); }); -- cgit