【发布时间】:2021-08-06 23:25:37
【问题描述】:
我正在使用 circleci 运行 cypress
workflows:
version: 2.1
test_and_release:
jobs:
- cypress/run:
working_directory: cats-client
start: npm start
wait-on: 'http://localhost:3000'
filters:
tags:
only: /v?\d+\.\d+(\.\d+)?/
branches:
only: /.*/
但它很糟糕等待命令
====>> Persisting to Workspace (skipped)
Warning: skipping this step: Missing workflow workspace identifiers, this step must be run in the context of a workflow
====>> Start
#!/bin/bash -eo pipefail
npm start
====>> Wait-on http://localhost:3000
#!/bin/bash -eo pipefail
npx wait-on http://localhost:3000
npx: installed 13 in 3.256s
Error:
Too long with no output (exceeded 10m0s): context deadline exceeded
Step timedout
Error: runner failed (exited with 101)
Task failed
Error: task failed
我试图解决这个问题降级react-scripts --> 3.4.0
https://github.com/facebook/create-react-app/issues/8688#issuecomment-602678446
但还是同样的问题
【问题讨论】:
-
在本地运行
npm start会得到什么? -
它工作得很好,当我在本地尝试该命令时 npm start & node_modules/.bin/cypress 运行它的工作
-
可以在本地试试
npm start & wait-on http://localhost:3000 && node_modules/.bin/cypress run吗? -
是的,这个命令在本地工作