随笔分类 - XUnit
摘要:https://xunit.github.io/docs/shared-context Shared Context between Tests It is common for unit test classes to share setup and cleanup code (often cal
阅读全文
摘要:https://docs.microsoft.com/en-us/dotnet/core/testing/unit-testing-best-practices
阅读全文
摘要:https://andrewlock.net/creating-parameterised-tests-in-xunit-with-inlinedata-classdata-and-memberdata/ MemberData 让测试类继承VersionList
阅读全文
摘要:1.https://xunit.github.io/docs/capturing-output 里面似乎提到2个方法,第二个方法还需要在配置文件中添加appSetting 这里采用第一种方法, 1.添加一个新的字段,并且通过构造函数初始化,这里的构造函数照着写就可以,不需要手动调用构造函数来传值 2
阅读全文
摘要:https://xunit.github.io/docs/getting-started-desktop.html In this article, we will demonstrate getting started with xUnit.net, showing you how to writ
阅读全文
摘要:安装 通过NuGet获取XUnit的类库 源码 https://github.com/xunit/xunit 介绍 xUnit.net is a free, open source, community-focused unit testing tool for the .NET Framework
阅读全文