bats-core / bats-support

Supporting library for Bats test helpers
Creative Commons Zero v1.0 Universal
41 stars 18 forks source link

Make it work with mocks and stubs #2

Closed Flamefire closed 1 year ago

Flamefire commented 5 years ago

Fixes https://github.com/ztombol/bats-support/issues/8 by saving the PATH and using command to ignore functions/aliases

Note: Needed to use a subshell as PATH="$_BATSLIB_PATH" command cat - did work for the tests but failed in a real world example and I can't figure out why. Even PATH="$_BATSLIB_PATH" command -v cat outputs the correct path.

martin-schulze-vireso commented 1 year ago

I am closing this in favor of #9, as I can't add code here (due to the master branch?).