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

Using --test option exits with code 2 #23

Closed
tzeikob opened this issue Jul 29, 2021 · 2 comments
Closed

Using --test option exits with code 2 #23

tzeikob opened this issue Jul 29, 2021 · 2 comments
Assignees
Labels
bug Something is not working

Comments

@tzeikob
Copy link
Owner

tzeikob commented Jul 29, 2021

The client exits with code 2 when using the --test option:

./releaze --bump major --test
@tzeikob tzeikob added the bug Something is not working label Jul 29, 2021
@tzeikob tzeikob self-assigned this Jul 30, 2021
@tzeikob
Copy link
Owner Author

tzeikob commented Jul 30, 2021

It seems that jest in using stderr to print output even for passed tests, this means the exec('npm', ['test']) will reject as well giving a false negative thrown error.

According to this #5064 open issue, jest still seems to be buggy.

Solution to this will be either to drop the --test option or to refactor exec to handle stderr as not error and resolve to { stdout, stderr } and leave the caller to decide what to do if stderr is not null.

Note: this is related only to those using jest for testing via npm test.

@tzeikob
Copy link
Owner Author

tzeikob commented Jul 30, 2021

Dropping the --test option seems to be the right choice for the moment.

Perhaps we can revisit this issue in the future.

@tzeikob tzeikob closed this as completed in 6478d7c Aug 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working
Projects
None yet
Development

No branches or pull requests

1 participant