Error handling and unit tests
[poolifier.git] / tests / dynamic.test.js
index 3784c65110b5161cbd9bb9a25b8eff0c0047d9ec..e23fd9af9fbd32ff210ef178f4cf298f7863af7c 100644 (file)
@@ -3,7 +3,7 @@ const DynamicThreadPool = require('../lib/dynamic')
 const min = 1
 const max = 3
 const pool = new DynamicThreadPool(min, max,
-  './tests/testWorker.js',
+  './tests/workers/testWorker.js',
   { errorHandler: (e) => console.error(e), onlineHandler: () => console.log('worker is online') })
 
 describe('Dynamic thread pool test suite ', () => {
@@ -57,7 +57,7 @@ describe('Dynamic thread pool test suite ', () => {
   })
 
   it('Should work even without opts in input', async () => {
-    const pool1 = new DynamicThreadPool(1, 1, './tests/testWorker.js')
+    const pool1 = new DynamicThreadPool(1, 1, './tests/workers/testWorker.js')
     const res = await pool1.execute({ test: 'test' })
     expect(res).toBeFalsy()
   })