Closed hollesse closed 4 months ago
its ok just trying to think of a way that helps us avoid contaminating our tests with such setup and teardown functionality. Did you try TestMain? https://blog.marcnuri.com/go-setting-up-and-tearing-down-unit-tests
Test Main would not be the right thing here. I want to explicitly set this, as I am expecting here that the application terminates. If I would use test main I would need to check everytime if there is the exit message in the output to check if the tools terminates where it should not terminate. We could think about having a testrunner for that, but I am not sure if this really introduces this tests, as it hides this behavior.
So what do you think about that @gregorriegler
Thank you
Closes #402. I needed to add the mock exit functionality here as the exiting leads to the test failing. If you have a better idea please let me know.