hbenl / vscode-jasmine-test-adapter

Jasmine Test Adapter for the VS Code Test Explorer
MIT License
20 stars 20 forks source link

The Jasmine test loader worker process finished with code 1 and signal null. #64

Closed dkadam77 closed 2 years ago

dkadam77 commented 2 years ago

The Jasmine test loader worker process finished with code 1 and signal null. c:\Users\XXXXX.vscode\extensions\hbenl.vscode-jasmine-test-adapter-1.8.1\node_modules\minimatch\minimatch.js:855 f = f.split(path.sep).join('/') ^

TypeError: Cannot read properties of null (reading 'split') at Minimatch.match (c:\Users\XXXXX.vscode\extensions\hbenl.vscode-jasmine-test-adapter-1.8.1\node_modules\minimatch\minimatch.js:855:13) at c:\Users\XXXXX.vscode\extensions\hbenl.vscode-jasmine-test-adapter-1.8.1\out\worker\patchJasmine.js:27:37 at Array.some () at findCallLocation (c:\Users\XXXXX.vscode\extensions\hbenl.vscode-jasmine-test-adapter-1.8.1\out\worker\patchJasmine.js:27:19) at Env.env. [as describe] (c:\Users\XXXXX.vscode\extensions\hbenl.vscode-jasmine-test-adapter-1.8.1\out\worker\patchJasmine.js:14:30) at describe (c:\Users\XXXXX\Documents\Salesforce_Workspace\Javascript\node_modules\jasmine-core\lib\jasmine-core\jasmine.js:8311:18) at file:///c:/Users/XXXXX/Documents/Salesforce_Workspace/Javascript/spec/calculator.spec.js:3:1 at ModuleJob.run (node:internal/modules/esm/module_job:198:25) at async Promise.all (index 0) at async ESMLoader.import (node:internal/modules/esm/loader:385:24)

hakonrk commented 2 years ago

Had the same problem, but found a workaround:

--- minimatch.js.orig   2022-07-29 02:57:00.362100300 +0200
+++ minimatch.js    2022-07-29 02:57:35.212679600 +0200
@@ -851,6 +851,7 @@
     const options = this.options

     // windows: need to use /, not \
+    if (f === null) return false;
     if (path.sep !== '/') {
       f = f.split(path.sep).join('/')
     }

With this patch to minimatch.js, the process will not crash due to the null path and everything seems to work. I did not bother looking into why the file path is null in the first place, or what it means to return false here.

hbenl commented 2 years ago

This should be fixed in version 1.8.2