-
Notifications
You must be signed in to change notification settings - Fork 178
Makefiles do not install test deps completely #1218
Copy link
Copy link
Closed
Labels
bugBugsBugsplannedIssues we will do in the next sprint.Issues we will do in the next sprint.testingImprovements or additions regarding the test setupImprovements or additions regarding the test setup
Description
🐞 Bug report
Describe the bug
Running make test or make integration-tests in a hook folder does not install npm depencies from /tests/integration. The CI does this step manually.
Steps To Reproduce
git clone https://github.com/secureCodeBox/secureCodeBox.git
cd hooks/cascading-scans
make test
Expected behavior
Integration tests should work
Screenshots / Logs
> @securecodebox/hook-cascading-scans@1.0.0 build
> npx tsc hook.ts --sourceMap --esModuleInterop
FAIL integration-tests/cascade-nmap-ncrack.test.js
● Test suite failed to run
Cannot find module '@kubernetes/client-node' from '../../../tests/integration/helpers.js'
Require stack:
/tmp/secureCodeBox/tests/integration/helpers.js
integration-tests/cascade-nmap-ncrack.test.js
3 | // SPDX-License-Identifier: Apache-2.0
4 |
> 5 | const k8s = require("@kubernetes/client-node");
| ^
6 |
7 | const kc = new k8s.KubeConfig();
8 | kc.loadFromDefault();
at Resolver.resolveModule (node_modules/jest-resolve/build/resolver.js:324:11)
at Object.<anonymous> (../../../tests/integration/helpers.js:5:13)
Fix
Run npm ci in /tests/integration
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugBugsBugsplannedIssues we will do in the next sprint.Issues we will do in the next sprint.testingImprovements or additions regarding the test setupImprovements or additions regarding the test setup