Testcafe Docker-错误:TypeScript编译失败。找不到名称';要求';

Testcafe Docker-错误:TypeScript编译失败。找不到名称';要求';,typescript,docker,testing,automated-tests,testcafe,Typescript,Docker,Testing,Automated Tests,Testcafe,当我尝试从最新的testcafe docker映像运行类型脚本时,我遇到以下错误 同样的脚本在旧版本docker pull testcafe/testcafe:1.4.3中运行良好 创建ts文件并添加以下代码 var config=require('./loginDetails.json'); 并尝试从testcafe docker运行它 使用的命令: docker run-v/var/jenkins/workspace/:/tests-i testcafe/testcafe'chromium-

当我尝试从最新的testcafe docker映像运行类型脚本时,我遇到以下错误

同样的脚本在旧版本docker pull testcafe/testcafe:1.4.3中运行良好

创建ts文件并添加以下代码

var config=require('./loginDetails.json'); 并尝试从testcafe docker运行它

使用的命令:

docker run-v/var/jenkins/workspace/:/tests-i testcafe/testcafe'chromium--no sandbox'/tests/*.ts'-e-u--selector timeout 10000--assertion timeout 10000-S-S/tests-r spec,xunit:/tests/res.xml,json:/tests/res.json-T'1681

错误:TypeScript编译失败。 /tests/commonFunctions.ts(2,14):找不到名称“require”。是否需要为节点安装类型定义?尝试
npmi@types/node
。 /tests/commonFunctions.ts(52,25):找不到名称“process”。是否需要为节点安装类型定义?尝试
npmi@types/node
。 /tests/commonFunctions.ts(53,13):找不到名称“process”。是否需要为节点安装类型定义?尝试
npmi@types/node
。 /tests/commonFunctions.ts(55,28):找不到名称“process”。是否需要为节点安装类型定义?尝试
npmi@types/node
。 /tests/commonFunctions.ts(89,22):找不到名称“require”。是否需要为节点安装类型定义?尝试
npmi@types/node
。 /tests/login.ts(3,14):找不到名称“require”。是否需要为节点安装类型定义?尝试
npmi@types/node

at Function._reportErrors (/usr/lib/node_modules/testcafe/src/compiler/test-file/formats/typescript/compiler.ts:79:15)
at TypeScriptTestFileCompiler._compileFilesToCache (/usr/lib/node_modules/testcafe/src/compiler/test-file/formats/typescript/compiler.ts:101:40)
at TypeScriptTestFileCompiler._precompileCode (/usr/lib/node_modules/testcafe/src/compiler/test-file/formats/typescript/compiler.ts:129:18)
at TypeScriptTestFileCompiler._compileCodeForTestFiles (/usr/lib/node_modules/testcafe/src/compiler/test-file/api-based.js:111:29)
at tsConfig.init.then (/usr/lib/node_modules/testcafe/src/compiler/test-file/formats/typescript/compiler.ts:85:30)

这个问题已经在TestCafe存储库中描述过了。跟踪它,以便在更新后得到通知


更新:我们已解决此问题。此问题已在TestCafe存储库中描述。跟踪它,以便在更新后得到通知

更新:我们已解决此问题。