TestFixtureData
The TestFixtureData class represents a set of arguments
and other parameter info to be used for a parameterized
fixture. It is derived from TestFixtureParameters and adds a
fluent syntax for use in initializing the fixture.
using NUnit.Framework.Interfaces;
using NUnit.Framework.Internal;
using System.Runtime.CompilerServices;
namespace NUnit.Framework
{
[System.Runtime.CompilerServices.NullableContext(1)]
[System.Runtime.CompilerServices.Nullable(0)]
public class TestFixtureData : TestFixtureParameters
{
[System.Runtime.CompilerServices.NullableContext(2)]
public TestFixtureData(params object[] args)
: base(args ?? new object[1])
{
}
[System.Runtime.CompilerServices.NullableContext(2)]
public TestFixtureData(object arg)
: base(arg)
{
}
[System.Runtime.CompilerServices.NullableContext(2)]
public TestFixtureData(object arg1, object arg2)
: base(arg1, arg2)
{
}
[System.Runtime.CompilerServices.NullableContext(2)]
public TestFixtureData(object arg1, object arg2, object arg3)
: base(arg1, arg2, arg3)
{
}
internal TestFixtureData SetName([System.Runtime.CompilerServices.Nullable(2)] string name)
{
base.TestName = name;
return this;
}
public TestFixtureData SetArgDisplayNames([System.Runtime.CompilerServices.Nullable(new byte[] {
2,
1
})] params string[] displayNames)
{
base.ArgDisplayNames = displayNames;
return this;
}
public TestFixtureData Explicit()
{
base.RunState = RunState.Explicit;
return this;
}
public TestFixtureData Explicit(string reason)
{
base.RunState = RunState.Explicit;
base.Properties.Set("_SKIPREASON", reason);
return this;
}
public TestFixtureData Ignore(string reason)
{
base.RunState = RunState.Ignored;
base.Properties.Set("_SKIPREASON", reason);
return this;
}
}
}