Table of Contents

Class NotFilter

Namespace
NUnit.Framework.Internal.Filters
Assembly
nunit.framework.dll

NotFilter negates the operation of another filter

public class NotFilter : TestFilter, ITestFilter
Inheritance
NotFilter
Implements
Inherited Members

Constructors

NotFilter(ITestFilter)

Construct a not filter on another filter

public NotFilter(ITestFilter baseFilter)

Parameters

baseFilter ITestFilter

The filter to be negated

Properties

BaseFilter

Gets the base filter

public ITestFilter BaseFilter { get; }

Property Value

ITestFilter

TopLevel

Indicates whether this is a top-level NotFilter, requiring special handling of Explicit

public bool TopLevel { get; set; }

Property Value

bool

Methods

Match(ITest)

Check whether the filter matches a test

public override bool Match(ITest test)

Parameters

test ITest

The test to be matched

Returns

bool

True if it matches, otherwise false

MatchDescendant(ITest)

Determine whether any descendant of the test matches the filter criteria.

protected override bool MatchDescendant(ITest test)

Parameters

test ITest

The test to be matched

Returns

bool

True if at least one descendant matches the filter criteria