TestScript.AssertReply 方法

定义

增加了一个断言,表明回合处理逻辑按预期响应。

public Microsoft.Bot.Builder.Dialogs.Adaptive.Testing.TestScript AssertReply(string expected, string description = default, uint timeout = 3000, string[] assertions = default, string path = "", int line = 0);
member this.AssertReply : string * string * uint32 * string[] * string * int -> Microsoft.Bot.Builder.Dialogs.Adaptive.Testing.TestScript
Public Function AssertReply (expected As String, Optional description As String = Nothing, Optional timeout As UInteger = 3000, Optional assertions As String() = Nothing, Optional path As String = "", Optional line As Integer = 0) As TestScript

参数

expected
String

机器人发来的预期短信。

description
String

如果实际回复不如预期,需要发送一条消息。

timeout
UInt32

即期望响应的时间(毫秒)。

assertions
String[]

断言。

path
String

路径。

line
Int32

行号。

返回

一个新 TestScript 对象,将该断言附加到建模交换中。

例外

机器人没有如预期回应。

注解

该方法不修改原始 TestScript 对象。

适用于