Udostępnij za pośrednictwem


DataRowAttribute Class

Definition

Attribute to define in-line data for a test method.

public ref class DataRowAttribute : Attribute, Microsoft::VisualStudio::TestTools::UnitTesting::ITestDataSource
[System.AttributeUsage(System.AttributeTargets.Method, AllowMultiple=true)]
public class DataRowAttribute : Attribute, Microsoft.VisualStudio.TestTools.UnitTesting.ITestDataSource
[<System.AttributeUsage(System.AttributeTargets.Method, AllowMultiple=true)>]
type DataRowAttribute = class
    inherit Attribute
    interface ITestDataSource
Public Class DataRowAttribute
Inherits Attribute
Implements ITestDataSource
Inheritance
DataRowAttribute
Attributes
Implements

Constructors

DataRowAttribute()

Initializes a new instance of the DataRowAttribute class.

DataRowAttribute(Object, Object[])

Initializes a new instance of the DataRowAttribute class which takes in an array of arguments.

DataRowAttribute(Object)

Initializes a new instance of the DataRowAttribute class.

Properties

Data

Gets data for calling test method.

DisplayName

Gets or sets display name in test results for customization.

Methods

GetData(MethodInfo)

Gets the test data from custom test data source.

GetDisplayName(MethodInfo, Object[])

Gets the display name corresponding to test data row for displaying in TestResults.

Applies to