From 0302f8ec510bb6a67a659e7fbc415c31429dfdcc Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Sat, 8 Oct 2022 15:23:33 +0200 Subject: [PATCH] Check in UTs the error message thrown in worker-thread pool MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- tests/pools/thread/fixed.test.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/pools/thread/fixed.test.js b/tests/pools/thread/fixed.test.js index 763e3f88..785c6e5d 100644 --- a/tests/pools/thread/fixed.test.js +++ b/tests/pools/thread/fixed.test.js @@ -103,6 +103,7 @@ describe('Fixed thread pool test suite', () => { expect(inError).toBeInstanceOf(Error) expect(inError.message).toBeDefined() expect(typeof inError.message === 'string').toBe(true) + expect(inError.message).toBe('Error Message from ThreadWorker') }) it('Verify that error handling is working properly:async', async () => { @@ -117,6 +118,7 @@ describe('Fixed thread pool test suite', () => { expect(inError).toBeInstanceOf(Error) expect(inError.message).toBeDefined() expect(typeof inError.message === 'string').toBe(true) + expect(inError.message).toBe('Error Message from ThreadWorker:async') }) it('Verify that async function is working properly', async () => { -- 2.34.1