I'm using ReSharper 4.5 to execute my MSTest unit tests in VS2008. With each test run, it's creating files in this path:
testProjectFolder\bin\Debug\TestResults
How can I clean/delete those files from within Visual Studio?
If I can't delete them from within Visual Studio, when can I expect them to be removed?
I see Visual Studio's Tools > Options > Test Tools > Test Execution > Test Results Management > Limit number of old Test Results to...
, and VS seems to honor it when you're using the stock VS test runner. ReSharper doesn't seem to honor that setting, and I don't see a similar setting in ReSharper. So, ReSharper's TestResults files just keep adding up on the disk?
I find the simplest way is to just add the following post-build step to my test project:
IF EXIST "$(TargetDir)TestResults" RD /S/Q "$(TargetDir)TestResults"
The TestResults folder in itself is not an artifact of ReSharper, but rather of MSTest itself.
Here's a blog post that describes one way of managing it, and here's the associated code snippet.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With