UITestAction 类

 

为用于用户界面 (UI) 测试的测试操作提供基类。

命名空间:   Microsoft.VisualStudio.TestTools.UITest.Common
程序集:  Microsoft.VisualStudio.TestTools.UITest.Common(Microsoft.VisualStudio.TestTools.UITest.Common.dll 中)

继承层次结构

System.Object
  Microsoft.VisualStudio.TestTools.UITest.Common.UITestAction
    Microsoft.VisualStudio.TestTools.UITest.Common.AggregatedAction
    Microsoft.VisualStudio.TestTools.UITest.Common.DelayAction
    Microsoft.VisualStudio.TestTools.UITest.Common.ErrorAction
    Microsoft.VisualStudio.TestTools.UITest.Common.InputAction
    Microsoft.VisualStudio.TestTools.UITest.Common.InvokeAction
    Microsoft.VisualStudio.TestTools.UITest.Common.MarkerAction
    Microsoft.VisualStudio.TestTools.UITest.Common.NoOperationAction
    Microsoft.VisualStudio.TestTools.UITest.Common.SystemAction
    Microsoft.VisualStudio.TestTools.UITest.Common.ValidationAction
    Microsoft.VisualStudio.TestTools.UITest.Common.VerifyConfigurationAction
    Microsoft.VisualStudio.TestTools.UITest.Common.WarningAction

语法

[SerializableAttribute]
public abstract class UITestAction : INotifyPropertyChanged
[SerializableAttribute]
public ref class UITestAction abstract : INotifyPropertyChanged
[<AbstractClass>]
[<SerializableAttribute>]
type UITestAction = 
    class
        interface INotifyPropertyChanged
    end
<SerializableAttribute>
Public MustInherit Class UITestAction
    Implements INotifyPropertyChanged

构造函数

名称 说明
System_CAPS_protmethod UITestAction()

初始化 UITestAction 类的新实例。

System_CAPS_protmethod UITestAction(UITechnologyElement)

使用提供的 UI 元素初始化 UITestAction 类的新实例。

属性

名称 说明
System_CAPS_pubproperty ActionLogEntry

获取或设置操作的事件日志项。

System_CAPS_pubproperty ActionName

获取操作的名称。此基类不支持 set 过程。

System_CAPS_pubproperty ActualThinkTime

获取或设置思考时间,在处理 UIActionInterpreter后提供的其他播放参数,如 ThinkTimeMultiplier

System_CAPS_pubproperty AdditionalInfo

当在派生类中实现时,获取包含自定义信息的字符串。

System_CAPS_pubproperty Comment

获取或设置此操作的注释。

System_CAPS_pubproperty ContinueOnError

获取或设置一个值,该值指示是否即使此操作失败也继续。

System_CAPS_pubproperty ContinueOnErrorWrapper

获取或设置字符串形式的 ContinueOnError 属性值,用于序列化。

System_CAPS_pubproperty ElapsedTime

获取或设置操作的时间跨度。

System_CAPS_pubproperty EndTimestamp

操作结束的时间戳。

System_CAPS_pubproperty Id

获取或设置此事件的唯一数字标识符。

System_CAPS_pubproperty IsParameterBound

如果此操作可参数化,则获取或设置一个值,用于指示该操作是否绑定到测试参数。

System_CAPS_pubproperty IsParameterizable

获取一个值,该值指示是否可以参数化此操作。

System_CAPS_pubproperty NeedFiltering

获取或设置一个值,该值指示此操作是否可以由 UITestActionFilter 处理。

System_CAPS_pubproperty ParameterName

获取或设置操作值的对应参数的名称。

System_CAPS_pubproperty StartTimestamp

获取或设置执行此操作时的起始时间戳。

System_CAPS_pubproperty Tags

获取关于此操作的附加信息的字典,在录制、聚合或后处理时需要这些信息。set 过程是私有的。

System_CAPS_pubproperty ThinkTime

获取或设置执行此操作所需的秒数。

System_CAPS_pubproperty Timestamp

获取或设置此操作的时间戳。

System_CAPS_pubproperty UIElement

获取或设置此操作所针对的 UI 元素。

System_CAPS_pubproperty UIObjectName

获取或设置此操作所针对的 UI 元素的名称。

System_CAPS_pubproperty UITestActionExtension

设置或获取包含属性与事件相关 UITestActionExtension 的实例。

System_CAPS_pubproperty ValueAsString

获取或设置此操作的 string 形式的值。此基类不支持 set 过程。

方法

名称 说明
System_CAPS_pubmethod Equals(Object)

返回一个值,该值表示给定对象是否等于此 UI 测试操作。(替代 Object.Equals(Object)。)

System_CAPS_protmethod Finalize()

(从 Object 继承。)

System_CAPS_pubmethod GetHashCode()

重写 object.GetHashCode(替代 Object.GetHashCode()。)

System_CAPS_pubmethod GetType()

(从 Object 继承。)

System_CAPS_pubmethod Invoke(UITestActionInvoker, UIMap)

调用此操作。

System_CAPS_protmethod MemberwiseClone()

(从 Object 继承。)

System_CAPS_protmethod NotifyPropertyChanged(String)

引发 PropertyChanged 事件。

System_CAPS_pubmethod ToString()

返回此操作的描述。(替代 Object.ToString()。)

事件

名称 说明
System_CAPS_pubevent PropertyChanged

在属性值更改时发生。

运算符

名称 说明
System_CAPS_puboperatorSystem_CAPS_static Equality(UITestAction, UITestAction)

重写“==”运算符以比较两个 UI 测试操作对象。

System_CAPS_puboperatorSystem_CAPS_static Inequality(UITestAction, UITestAction)

重写“!=”运算符以比较两个 UI 测试操作对象。

线程安全

此类型的任何公共静态(Visual Basic 中为 Shared)成员都是线程安全的。但不保证所有实例成员都是线程安全的。

请参阅

INotifyPropertyChanged
Microsoft.VisualStudio.TestTools.UITest.Common 命名空间

返回页首