You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have noticed a number of times in use of the Kit tests subpackage that there exists a race when using tests.ResetLog() and tests.DisplayLog(), especially when parrallel tests are allowed, we need to wrap those calls with mutex to avoid such a case.
The text was updated successfully, but these errors were encountered:
This does not really solve the problem. Running Test functions in parallel will still require tests to be sharing the same buffer, which is not what we want. We use the ./... to run package tests in parallel but this was not designed to run test function within a package in parallel. I'm not sure we want or need to support that. Let's talk.
This will not solve the problem you wish to solve. The log package acts as a singleton and this code supports that assumption per package. If you want to run test functions in parallel inside a package, you will need a TestMain and call these functions once.
I have noticed a number of times in use of the Kit tests subpackage that there exists a race when using tests.ResetLog() and tests.DisplayLog(), especially when parrallel tests are allowed, we need to wrap those calls with mutex to avoid such a case.
The text was updated successfully, but these errors were encountered: