共用方式為


IgnoreAttribute Class

Definition

This attribute is used to ignore a test class or a test method, with an optional message.

[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false)]
public sealed class IgnoreAttribute : Attribute
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method)]
public sealed class IgnoreAttribute : Attribute
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, Inherited=false)]
public sealed class IgnoreAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false)>]
type IgnoreAttribute = class
    inherit Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method)>]
type IgnoreAttribute = class
    inherit Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, Inherited=false)>]
type IgnoreAttribute = class
    inherit Attribute
Public NotInheritable Class IgnoreAttribute
Inherits Attribute
Inheritance
IgnoreAttribute
Attributes

Remarks

This attribute isn't inherited. Applying it to a base class will not cause derived classes to be ignored.

Constructors

IgnoreAttribute()

Initializes a new instance of the IgnoreAttribute class with an empty message.

IgnoreAttribute(String)

Initializes a new instance of the IgnoreAttribute class.

Properties

IgnoreMessage

Gets the ignore message indicating the reason for ignoring the test method or test class.

Applies to