Can you mark XUnit tests as Explicit?

后端 未结 4 1418
你的背包
你的背包 2021-02-05 05:43

I\'m making the transition from NUnit to XUnit (in C#), and I was writing some \"Integrated Tests\" (ITs) that I don\'t necessarily want the test runner to run as part of my aut

4条回答
  •  温柔的废话
    2021-02-05 05:56

    I think I found it. Apparently, you can modify your [Fact] attribute like so: [Fact(Skip="reason")]. This will skip the test, but you'll have no way of running it manually without modifying the attribute back to normal.

    I'll keep looking for a better way.

提交回复
热议问题