Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(runner): return correct exit code when something fails #95

Merged
merged 1 commit into from
Apr 29, 2021

Conversation

alimnios72
Copy link
Contributor

  • Added correct exit code when test fails
  • Added correct exit code when file fails execution
  • Added correct exit code when forbid-focused option is passed and there is at least one focused test

fixes #94

@alimnios72 alimnios72 added the bug Something isn't working label Apr 29, 2021
@alimnios72 alimnios72 requested review from sjbarag and lkipke April 29, 2021 18:47
@alimnios72 alimnios72 self-assigned this Apr 29, 2021
Copy link
Contributor

@lkipke lkipke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks for the fix!

Copy link
Contributor

@sjbarag sjbarag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! If we wanted to be super unix nerds we could make the return code be the number of failed tests, but I'm 10000% okay with just returning 1 😃

Excellent work @alimnios72 — thanks for jumping on this so fast!

@alimnios72
Copy link
Contributor Author

alimnios72 commented Apr 29, 2021

If we wanted to be super unix nerds we could make the return code be the number of failed tests

yeah that's something we can try in the future, I wonder if the CI/CD gets any benefit if having exit codes different than 1? maybe github shows that number when a PR fails?

@alimnios72 alimnios72 merged commit df5f92c into hulu:main Apr 29, 2021
@alimnios72 alimnios72 deleted the bugs/wrong-exit-codes branch April 29, 2021 19:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incorrect exit code is returned when npm test fails
3 participants