标签: .net visual-studio visual-studio-2008 unit-testing nunit
我正在将NUnit测试“翻译”为Visual Studios单元测试,我想知道VS中的属性[ClassInitialize()]是否等同于NUnit中的[SetUp()]?
[ClassInitialize()]
[SetUp()]
答案 0 :(得分:11)
[SetUp]对应[TestInitialize]
[SetUp]
[TestInitialize]
[TestFixtureSetUp]对应[ClassInitialize]
[TestFixtureSetUp]
[ClassInitialize]
Here's the full picture