angular - 终端错误:架构验证失败,出现以下错误:数据路径“['polyfills']”应该是数组
问题描述
我刚刚使用ng new <projectName>
. 然后我通过使用ng add @cypress/schematic
和更改了默认测试设置ng add @briebug/jest-schematic
package.lock
以供参考:
{
"name": "betting-app",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"cypress:open": "cypress open",
"cypress:run": "cypress run"
},
"private": true,
"dependencies": {
"@angular/animations": "~11.1.2",
"@angular/common": "~11.1.2",
"@angular/compiler": "~11.1.2",
"@angular/core": "~11.1.2",
"@angular/forms": "~11.1.2",
"@angular/platform-browser": "~11.1.2",
"@angular/platform-browser-dynamic": "~11.1.2",
"@angular/router": "~11.1.2",
"@briebug/jest-schematic": "^3.1.0",
"rxjs": "~6.6.0",
"tslib": "^2.0.0",
"zone.js": "~0.11.3"
},
"devDependencies": {
"@angular-builders/jest": "latest",
"@angular-devkit/build-angular": "~0.1101.4",
"@angular/cli": "~11.1.4",
"@angular/compiler-cli": "~11.1.2",
"@cypress/schematic": "^1.5.3",
"@types/jasmine": "~3.6.0",
"@types/jest": "latest",
"@types/node": "^12.11.1",
"codelyzer": "^6.0.0",
"jasmine-core": "~3.6.0",
"jasmine-spec-reporter": "~5.0.0",
"jest": "latest",
"karma-coverage": "~2.0.3",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint": "~6.1.0",
"typescript": "~4.1.2",
"cypress": "latest"
}
}
当我运行时,ng test
我得到了上述错误,并且正在努力如何让我的测试运行。任何帮助都会很棒!提前致谢。
解决方案
推荐阅读
- python - 使用 pymongo 进行 mongo 身份验证
- c++ - 内联析构函数“导致”bad_alloc
- python - 检查提到的用户是否有一定的权限 discord.py
- webpack - 使用 webpack 提供静态资源
- java - 将字符串数组反序列化为csv
- flutter - Flutter - 无需点击即可在屏幕加载中检索 MobX @action 返回值
- imagemagick - 如何使 ImageMagick 在复合操作中尊重颜色配置文件?
- docker - 收到错误“状态 400:客户端向 HTTPS 服务器发送了 HTTP 请求。” 在 IntelliJ 上连接到 Docker 时
- google-cloud-platform - 使用 Cloud Shell 的 Google Cloud Vision API:如何为多个图像运行 API?我的 request.json 应该是什么样的?
- google-cloud-platform - Google Cloud Run:内存不足(错误?)