All Projects → brendanconnolly → Xunit.Categories

brendanconnolly / Xunit.Categories

Licence: Apache-2.0 license
Friendlier attributes to help categorize your tests

Programming Languages

C#
18002 projects

Labels

Projects that are alternatives of or similar to Xunit.Categories

Xunit
xUnit.net is a free, open source, community-focused unit testing tool for the .NET Framework.
Stars: ✭ 3,120 (+3570.59%)
Mutual labels:  xunit
MinimalApi
ASP.NET Core 7.0 - Minimal API Example - Todo API implementation using ASP.NET Core Minimal API, Entity Framework Core, Token authentication, Versioning, Unit Testing, Integration Testing and Open API.
Stars: ✭ 156 (+83.53%)
Mutual labels:  xunit
xunit.testlogger
XUnit logger for vstest platform
Stars: ✭ 65 (-23.53%)
Mutual labels:  xunit
Specflow
#1 .NET BDD Framework. SpecFlow automates your testing & works with your existing code. Find Bugs before they happen. Behavior Driven Development helps developers, testers, and business representatives to get a better understanding of their collaboration
Stars: ✭ 1,827 (+2049.41%)
Mutual labels:  xunit
bUnit
bUnit is a testing library for Blazor components that make tests look, feel, and runs like regular unit tests. bUnit makes it easy to render and control a component under test’s life-cycle, pass parameter and inject services into it, trigger event handlers, and verify the rendered markup from the component using a built-in semantic HTML comparer.
Stars: ✭ 857 (+908.24%)
Mutual labels:  xunit
MsCoreOne
MsCoreOne is a simple Ecommerce with using many technologies such as .NET 5, Entity Framework Core 5, React 16.13 with modern Clean Architecture, Domain-Driven Design, CQRS, SOLID, Identity Server 4, Blazor. It will focus on resolving the problems always see in the process to develop projects.
Stars: ✭ 77 (-9.41%)
Mutual labels:  xunit
mpunit
Mini PHP xUnit Testing Framework
Stars: ✭ 15 (-82.35%)
Mutual labels:  xunit
kekiri
A .NET framework that supports writing low-ceremony BDD tests using Gherkin language
Stars: ✭ 19 (-77.65%)
Mutual labels:  xunit
XunitContext
Extends xUnit to expose extra context and simplify logging
Stars: ✭ 127 (+49.41%)
Mutual labels:  xunit
bitrix-module-bunit
BUnit - фреймворк модульного тестрования для CMS Bitrix
Stars: ✭ 20 (-76.47%)
Mutual labels:  xunit
Fluentassertions
A very extensive set of extension methods that allow you to more naturally specify the expected outcome of a TDD or BDD-style unit tests. Targets .NET Framework 4.7, .NET Core 2.1 and 3.0, as well as .NET Standard 2.0 and 2.1. Supports the unit test frameworks MSTest2, NUnit3, XUnit2, MSpec, and NSpec3.
Stars: ✭ 2,449 (+2781.18%)
Mutual labels:  xunit
resharper-xunit-templates
ReSharper Live Templates for xUnit.net
Stars: ✭ 18 (-78.82%)
Mutual labels:  xunit
toolbox
dein ToolBox - C# .Net Library with utilities like: command line, files, log, platform, shell, system, transform and validation [ Win+Mac+Linux ]
Stars: ✭ 46 (-45.88%)
Mutual labels:  xunit
Cake
🍰 Cake (C# Make) is a cross platform build automation system.
Stars: ✭ 3,154 (+3610.59%)
Mutual labels:  xunit
ArchitectNow.ApiStarter
Sample ASP.NET Core 2 API Setup used by ArchitectNow for corresponding workshop presentations
Stars: ✭ 35 (-58.82%)
Mutual labels:  xunit
xRetry
Retry running tests via Xunit and Specflow
Stars: ✭ 15 (-82.35%)
Mutual labels:  xunit
xharness
C# command line tool for running tests on Android / iOS / tvOS devices and simulators
Stars: ✭ 123 (+44.71%)
Mutual labels:  xunit
testcontainers-dotnet
dotnet port of testcontainers-java
Stars: ✭ 22 (-74.12%)
Mutual labels:  xunit
FakeItEasy.AutoFakeIt
A very simple, yet flexible, "AutoFaker" for FakeItEasy to easily auto generate classes with faked dependencies.
Stars: ✭ 15 (-82.35%)
Mutual labels:  xunit
xunit-to-junit
This Extensible Stylesheet Language Transformations can transform a xUnit.net v2 XML test results file into a JUnit test results file.
Stars: ✭ 21 (-75.29%)
Mutual labels:  xunit

Xunit.Categories

Friendlier attributes to help categorize your tests.

Messy Traits?

The xUnit built in option Traits can get a little messy. Its just 2 strings representing a key and value, unless you are familiar with xUnit and the Trait attribute it looks a little magical.

Also both key and value must be specified on the command line. This means if you decorate your test with [Trait("Category","Bug")] you cannot run only tests from a specific bug without adding another trait ([Trait("Bug","8675309"])

Friendly Attributes Included

  • Category
  • Feature
  • User Story
  • Bug
  • Integration Test
  • Unit Test
  • Exploratory
  • Documentation
  • Known Bug
  • Work Item
  • System Test
  • Test Case

Open an issue or pull request to add more.

Example

[Fact]
[Bug]
public void TestBug()
{
    throw new NotImplementedException("I'm a bug");
}

[Fact]
[Bug("777")]
public void TestBugWithId()
{
    throw new NotImplementedException("I've got your number");
}

Using this attribute you get descriptive information and flexibility when running tests. You can run all tests marked as Bugs

xunit.console.exe ... -trait "Category=Bug"

-or via dotnet test

dotnet test --filter "Category=Bug" 

or get more granular

xunit.console.exe ... -trait "Bug=777"

-or via dotnet test
dotnet test --filter "Bug=777" 
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].