I am doing a big merge, and as you can imagine, some tests are failing. I am currently just to get it out the door, and failing tests are really annoying.
I identified the problem, but resolving it would be too hard right now, so I opted for the following solution instead:
Comments
What a nice time bomb planted under your desk! The future version of you will course the past version.
*curse
"identified the problem, but resolving it would be too hard right now" - it will be even harder later.
Not using your SystemTime class for that one then :D
Maybe you should throw a TimeoutException instead ... ;)
// Ryan
@Franky Junge - that would make it tempting to fix the issue with: SystemTime.Now = () => new DateTime(2000,1,1); :-)
Wouldn't it be more useful to Assert.Inconclusive on the test that failed until the time was up and then just run the test as normal? At least then it would report on the correct test.
Matt, Assert.Inconclusive is not a feature of XUnit. And we don't want to have an inconclusive test, we want one that doesn't run until a specific time.
I have done this in the past. Just try and resist editing and pushing the date back three times before you really fix it! :-)
Comment preview