dnt
dnt copied to clipboard
When generating a build, @deno/shim-deno-test/dist/test.js fails
I am getting the following with dnt 0.30.0 (also tried 0.29.1):
Running tests in ./script/gustwind/npm/node_modules/@deno/shim-deno-test/dist/test.js...
Error: Cannot find module './definitions.js'
Require stack:
- /Users/juhovepsalainen/Projects/github/gustwindjs/gustwind/breezewind/npm/script/gustwind/npm/node_modules/@deno/shim-deno-test/dist/test.js
- /Users/juhovepsalainen/Projects/github/gustwindjs/gustwind/breezewind/npm/test_runner.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/Users/juhovepsalainen/Projects/github/gustwindjs/gustwind/breezewind/npm/script/gustwind/npm/node_modules/@deno/shim-deno-test/dist/test.js:4:26)
at Module._compile (node:internal/modules/cjs/loader:1103:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1157:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/Users/juhovepsalainen/Projects/github/gustwindjs/gustwind/breezewind/npm/script/gustwind/npm/node_modules/@deno/shim-deno-test/dist/test.js',
'/Users/juhovepsalainen/Projects/github/gustwindjs/gustwind/breezewind/npm/test_runner.js'
]
}
It's running tests for @deno/shim-deno-test but I don't understand why. I would expect it would run only the package tests.
To reproduce:
- Clone https://github.com/gustwindjs/gustwind/tree/bug/dnt-test
vr build:breezewind-for-npm 0.4.1
I encountered a similar issue:
Running tests in ./script/examples/nodejs_commonjs/node_modules/@deno/shim-deno-test/dist/test.js...
Error: Cannot find module './definitions.js'
Deleting the node_modules folder in my examples/nodejs_commonjs folder worked for me.