Has.Attribute 方法

定义

重载

Attribute(Type)

返回一个新的 AttributeConstraint 检查对象上是否存在特定属性。

Attribute<T>()

返回一个新的 AttributeConstraint 检查对象上是否存在特定属性。

Attribute(Type)

返回一个新的 AttributeConstraint 检查对象上是否存在特定属性。

public static NUnit.Framework.Constraints.ResolvableConstraintExpression Attribute (Type expectedType);
static member Attribute : Type -> NUnit.Framework.Constraints.ResolvableConstraintExpression

参数

expectedType
Type

返回

适用于

Attribute<T>()

返回一个新的 AttributeConstraint 检查对象上是否存在特定属性。

public static NUnit.Framework.Constraints.ResolvableConstraintExpression Attribute<T> ();
static member Attribute : unit -> NUnit.Framework.Constraints.ResolvableConstraintExpression

类型参数

T

返回

适用于