Closed natemcmaster closed 6 years ago
I can't fix the test without making a change to allow mocking a static method, so what do you propose we do?
I just posted a comment to the issue thread: can we disable parallelization of these tests?
The flakiness is not an issue with parallelization. It is a problem with bad machine state.
If we disable parallelization can we have cleanup code that runs before/after each affected test so that they're guaranteed not to clobber over each other?
It's not about parallelization. The global machine folder may be there for a number of reasons which disabling parallelization does not solve. when the global machine folder exists, the test attempts to avoid clobbering it by moving it temporarily. But moving it is what is causing problems. The location of the global machine folder is uninteresting in this test, which is why the fix for the flakiness is to use a different folder.
What risk is there in disabling these tests for the patch?
What risk is there in disabling these tests for the patch?
We lose regression coverage. If you'd rather risk that, then let's just get rid of the test.
I think if we don't have a reasonable way of de-flakifying the test without product changes then we should disable the test.
Per in person discussion, this is not okay because our default policy prohibits any change to anything in the product at all regardless of confidence that the changes are not going to break someone. The only exception is for changes which provide high value to customers, and flaky test fixes do not.
Create an internal abstraction for finding the default directories for key storage. This allows us to run tests without squashing on keys on the developer machine. It also allows us to isolate test runs from reach other.
Fixes aspnet/Home#3034