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
It is possible to add output formatters to unittest, but it is not possible to remove them.
Description
This is an issue for the JUnit output format (see #2088) when you have more than one test suite that are creating their own output files. Once the first suite is done and closes its output stream, the output formatter is still in the seq of formatters that is maintained inside of unittest.nim. Once the second test suite starts producing output, an exception is raised since the stream is closed.
Alternatives
Alternative implementations could include the ability to mark an OutputFormatter as no longer active, but that would require updating other code in unittest.nim to look for that flag and honor it. Being able to just remove the formatter when a suite is finished seems simpler.
The text was updated successfully, but these errors were encountered:
Summary
It is possible to add output formatters to unittest, but it is not possible to remove them.
Description
This is an issue for the JUnit output format (see #2088) when you have more than one test suite that are creating their own output files. Once the first suite is done and closes its output stream, the output formatter is still in the seq of formatters that is maintained inside of unittest.nim. Once the second test suite starts producing output, an exception is raised since the stream is closed.
Alternatives
Alternative implementations could include the ability to mark an OutputFormatter as no longer active, but that would require updating other code in unittest.nim to look for that flag and honor it. Being able to just remove the formatter when a suite is finished seems simpler.
The text was updated successfully, but these errors were encountered: