<PackageReference Include="NUnit" Version="4.6.0" />

NUnit.Framework.IncludeExcludeAttribute

public abstract class IncludeExcludeAttribute : NUnitAttribute
Abstract base for attributes that are used to include tests in the test run based on environmental settings.
public string Exclude { get; set; }

Name of the item to be excluded. Multiple items may be given, separated by a comma.

public string[] Excludes { get; set; }

An array of items to be excluded.

public string Include { get; set; }

Name of the item that is needed in order for a test to run. Multiple items may be given, separated by a comma.

public string[] Includes { get; set; }

An array of items to be included.

public string Reason { get; set; }

The reason for including or excluding the test

Constructor with no included items specified, for use with named property syntax.

protected IncludeExcludeAttribute(string include)

Constructor taking one or more included items

protected IncludeExcludeAttribute(string[] includes)

Constructor taking an array of included items