TypedDevs / bashunit

A simple testing library for bash scripts. Test your bash scripts in the fastest and simplest way, discover the most modern bash testing library.
https://bashunit.typeddevs.com
MIT License
271 stars 21 forks source link

Add unmock function #212

Closed Chemaclass closed 7 months ago

Chemaclass commented 8 months ago

📚 Description

Currently, you can mock a particular function with custom logic, but there is no way to rollback the mock for other tests. It would be useful to be able to remove/rollback the mocked behaviour.

🔖 Changes

All mocks will be removed/rollback to their original behaviour after each test. This means that the mock live scope is tied to the test scope

✅ To-do list

antonio-gg-dev commented 8 months ago

@Chemaclass this is more complex than we anticipated, do you mind if we leave it in draft until we can get together? Besides, I think it's more priority to refactor the acceptance tests and finish the snapshots.

Chemaclass commented 7 months ago

Close because inactivity. I will open it again to seek for new feedback