question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`cypress ci` does not issue proper exit code in Codeship CI

See original GitHub issue

I am having an issue when running tests in Codeship. The tests should exit with the number of failures, but instead it times out.

Error Message

--------------------------------------------------------------------------------
This command didn't output anything for 10 minutes, thus we stopped it.
Please make sure your steps regularly print to standard out or standard error.
If the error is on our end please inform us so we can help you to fix this.
--------------------------------------------------------------------------------

Screenshot screen shot 2016-12-06 at 11 18 27 am

Codeship’s support team input

I took a look at some of your builds and I’m wondering more about the cypress ci command. It looks like it finishes, but maybe isn’t giving an exit code? Codeship relies on scripts/commands providing a meaningful exit code to know when the command is done and also to then know to move on to the next command or if the build should be failed.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:3
  • Comments:37 (21 by maintainers)

github_iconTop GitHub Comments

3reactions
brian-manncommented, Jul 9, 2018

Also just wanted to say you are awesome @joesiewert as I don’t think we would have ever been able to figure this out, haha.

3reactions
bgschillercommented, Apr 20, 2018

I was bit by this yesterday, and came up with a workaround script. It’s not a long-term solution, but I’m posting here because it could be useful to someone: https://gist.github.com/bgschiller/397ad1ca123aa15f331f3f3ec9717e5f

The workaround is:

  • Wrap Cypress with a script that watches its output
  • wait for all tests to finish, collect the failed tests count
  • kill cypress subprocess
  • then exit with an appropriate code (based on the failed test count)
Read more comments on GitHub >

github_iconTop Results From Across the Web

Introduction | Cypress Documentation
When you boot your web server, it runs as a long running process that will never exit. Because of this, you'll need it...
Read more >
cypress-io/cypress - Gitter
Hello, I want to use cy.request() to send file through API. However, it's always return status code 400 bad request. Is anyone know...
Read more >
Continuous Integration - cypress - w3resource
Whenever you boot your web server, it will run as long as there is a long running process that will never exit. This...
Read more >
Configuring Test Coverage - Code Climate
You must instrument test coverage yourself as part of your CI build (in one of our supported ... If this many arguments are...
Read more >
Marcel (@marceldegraaf) / Twitter
`cypress ci` does not issue proper exit code in Codeship CI · Issue #328 · cypress-io/cypress. I am having an issue when running...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found