IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
TestCaseAttribute is used to mark parameterized test cases and provide them with their arguments. More...
Public Member Functions | |
TestCaseAttribute (params object[] arguments) | |
Construct a TestCaseAttribute with a list of arguments. This constructor is not CLS-Compliant More... | |
TestCaseAttribute (object arg) | |
Construct a TestCaseAttribute with a single argument More... | |
TestCaseAttribute (object arg1, object arg2) | |
Construct a TestCaseAttribute with a two arguments More... | |
TestCaseAttribute (object arg1, object arg2, object arg3) | |
Construct a TestCaseAttribute with a three arguments More... | |
IEnumerable< TestMethod > | BuildFrom (IMethodInfo method, Test suite) |
Construct one or more TestMethods from a given MethodInfo, using available parameter data. More... | |
![]() | |
NUnitAttribute () | |
Default constructor More... | |
Properties | |
string | TestName [get, set] |
Gets or sets the name of the test. More... | |
RunState | RunState [get, private set] |
Gets or sets the RunState of this test case. More... | |
object[] | Arguments [get, private set] |
Gets the list of arguments to a test case More... | |
IPropertyBag | Properties [get, private set] |
Gets the properties of the test case More... | |
object | ExpectedResult [get, set] |
Gets or sets the expected result. More... | |
bool | HasExpectedResult [get, private set] |
Returns true if the expected result has been set More... | |
string | Description [get, set] |
Gets or sets the description. More... | |
string | Author [get, set] |
The author of this test More... | |
Type | TestOf [get, set] |
The type that this test is testing More... | |
string | Ignore [get, set] |
Gets or sets the reason for ignoring the test More... | |
bool | Explicit [get, set] |
Gets or sets a value indicating whether this NUnit.Framework.TestCaseAttribute is explicit. More... | |
string | Reason [get, set] |
Gets or sets the reason for not running the test. More... | |
string | IgnoreReason [get, set] |
Gets or sets the ignore reason. When set to a non-null non-empty value, the test is marked as ignored. More... | |
string | IncludePlatform [get, set] |
Comma-delimited list of platforms to run the test for More... | |
string | ExcludePlatform [get, set] |
Comma-delimited list of platforms to not run the test for More... | |
string | Category [get, set] |
Gets and sets the category for this test case. May be a comma-separated list of categories. More... | |
![]() | |
object | ExpectedResult [get] |
Gets the expected result of the test case More... | |
bool | HasExpectedResult [get] |
Returns true if an expected result has been set More... | |
![]() | |
string | TestName [get] |
Gets the name to be used for the test More... | |
RunState | RunState [get] |
Gets the RunState for this test case. More... | |
object[] | Arguments [get] |
Gets the argument list to be provided to the test More... | |
IPropertyBag | Properties [get] |
Gets the property dictionary for the test case More... | |
Private Member Functions | |
TestCaseParameters | GetParametersForTestCase (IMethodInfo method) |
Static Private Member Functions | |
static void | PerformSpecialConversions (object[] arglist, IParameterInfo[] parameters) |
Performs several special conversions allowed by NUnit in order to permit arguments with types that cannot be used in the constructor of an Attribute such as TestCaseAttribute or to simplify their use. More... | |
Private Attributes | |
object | _expectedResult |
Type | _testOf |
TestCaseAttribute is used to mark parameterized test cases and provide them with their arguments.
|
inline |
Construct a TestCaseAttribute with a list of arguments. This constructor is not CLS-Compliant
arguments |
|
inline |
Construct a TestCaseAttribute with a single argument
arg |
|
inline |
Construct a TestCaseAttribute with a two arguments
arg1 | |
arg2 |
|
inline |
Construct a TestCaseAttribute with a three arguments
arg1 | |
arg2 | |
arg3 |
|
inlineprivate |
|
inlinestaticprivate |
Performs several special conversions allowed by NUnit in order to permit arguments with types that cannot be used in the constructor of an Attribute such as TestCaseAttribute or to simplify their use.
arglist | The arguments to be converted |
parameters | The ParameterInfo array for the method |
References NUnit.Framework.Interfaces.IParameterInfo.ParameterType.
|
inline |
Construct one or more TestMethods from a given MethodInfo, using available parameter data.
method | The MethodInfo for which tests are to be constructed. |
suite | The suite to which the tests will be added. |
Implements NUnit.Framework.Interfaces.ITestBuilder.
References NUnit.Framework.Interfaces.IPropertyBag.Add(), NUnit.Framework.Internal.Builders.NUnitTestCaseBuilder.BuildTestMethod(), NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported(), NUnit.Framework.Internal.Test.Properties, NUnit.Framework.Internal.PlatformHelper.Reason, NUnit.Framework.Internal.Test.RunState, and NUnit.Framework.Internal.PropertyNames.SkipReason.
Referenced by NUnit.Framework.Attributes.TestMethodBuilderTests.TestCaseAttribute_NoArgs_NotRunnable(), NUnit.Framework.Attributes.TestMethodBuilderTests.TestCaseAttribute_RightArgs_Runnable(), and NUnit.Framework.Attributes.TestMethodBuilderTests.TestCaseAttribute_WrongArgs_NotRunnable().
|
private |
|
private |
|
getset |
Gets or sets the name of the test.
The name of the test.
|
getprivate set |
Gets or sets the RunState of this test case.
|
getprivate set |
Gets the list of arguments to a test case
|
getprivate set |
Gets the properties of the test case
|
getset |
Gets or sets the expected result.
The result.
|
getprivate set |
Returns true if the expected result has been set
|
getset |
Gets or sets the description.
The description.
|
getset |
The author of this test
|
getset |
The type that this test is testing
|
getset |
Gets or sets the reason for ignoring the test
|
getset |
Gets or sets a value indicating whether this NUnit.Framework.TestCaseAttribute is explicit.
true
if explicit; otherwise, false
.
|
getset |
Gets or sets the reason for not running the test.
The reason.
|
getset |
Gets or sets the ignore reason. When set to a non-null non-empty value, the test is marked as ignored.
The ignore reason.
|
getset |
Comma-delimited list of platforms to run the test for
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
getset |
Comma-delimited list of platforms to not run the test for
Referenced by NUnit.Framework.Internal.PlatformHelper.IsPlatformSupported().
|
getset |
Gets and sets the category for this test case. May be a comma-separated list of categories.