akauppi / GroundLevel-firebase-es

[ANCHORED] Stencil for operational web apps
https://groundlevel-sep22.web.app/
Other
23 stars 3 forks source link

Error `linking error, not in local cache`, running backend tests #31

Closed akauppi closed 3 years ago

akauppi commented 3 years ago

This is a mysterious error, not found any reference online about it.

Steps to reproduce:

$ cd packages/backend
$ npm install
$ npm run start     # leave running

In second terminal:

$ npm run test:fns:userInfo 

> test:fns:userInfo
> GCLOUD_PROJECT=bunny NODE_OPTIONS=--experimental-vm-modules npx jest --config test-fns/jest.config.cjs -f userInfo.test.js --verbose --detectOpenHandles --all

(node:83950) ExperimentalWarning: VM Modules is an experimental feature. This feature could change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
 FAIL  test-fns/userInfo.test.js
  ● Test suite failed to run

    linking error, not in local cache

Test Suites: 1 failed, 1 total
Tests:       0 total
Snapshots:   0 total
Time:        0.571 s
Ran all test suites matching /userInfo.test.js/i.

I have been unable to even find more detailed information, what goes wrong.

akauppi commented 3 years ago

Based on this it can be related to node.

(. ) Test with earlier (eg. node 14)

akauppi commented 3 years ago

This was a Jest problem; solved.