postmodern / chruby

Changes the current Ruby
MIT License
2.88k stars 189 forks source link

Fix tests so that they also work locally #471

Closed FranklinYu closed 2 years ago

FranklinYu commented 2 years ago

The test works in GitHub Action environment, but it doesn’t work on all environments. This PR is trying to make the test more robust, and allow it to run on more environments (such as the one I develop on).

FranklinYu commented 2 years ago

Quote from Bash manual supporting 49c9b49c26da6dbad71c4fac6073984101e3a84f:

If a numeric argument is given to return, that is the function’s return status; otherwise the function’s return status is the exit status of the last command executed before the return.

Example:

func() { return; }

false
func || echo 'Error!'
postmodern commented 2 years ago

Merged!