我在Cypress上取得了不错的进步,但是在尝试调用单个Spec时有点不高兴。
package.json
中的行如下所示:
"cypress:runST": "cypress run --spec'/cypress/integration/02_DBM_H1_ST_spec.js'",
我从npm run cypress:runST
...错误开始!
即使我尝试将其运行为:
`npm run cypress run --spec '/cypress/integration/02_DBM_H1_ST_spec.js'
我仍然遇到错误:
Can't run because no spec files were found.
We searched for any files matching this glob pattern:
'\cypress\integration\02_DBM_H1_ST_spec.js'
和来自NPM日志:
10 silly lifecycle cypress_research@1.0.0~cypress:runST: Args: [ '/d /s /c',
10 silly lifecycle 'cypress run --spec \'/cypress/integration/02_DBM_H1_ST_spec.js\'' ]
11 silly lifecycle cypress_research@1.0.0~cypress:runST: Returned: code: 1 signal: null
12 info lifecycle cypress_research@1.0.0~cypress:runST: Failed to exec cypress:runST script
我感觉这是命令中的语法,但是如果是这种情况,它将再次运行“ bare”。.但是我遇到了同样的错误。不知道'。'规格和.js之后的来源。
有什么想法吗? 谢谢