使用 mochawesome 与 Botium-cli 的对话流:未定义的按钮

Dialogflow with Botium-cli using mochawesome : undefined Buttons

按钮在机器人回复中有效,但在 mochawesome 中#bot 回复未定义

样本对话 #机器人 BUTTON Pin 邮寄器

#我 Pin 邮件程序

#机器人 按钮拿起|返回菜单

#我 拿起

但在 mochawesome 机器人响应未定义 我正在使用

botium-cli run mochawesome.

screenshot mochawesome Conversation Log

目前,Botium CLI 中的 mochawesome 记者只能处理短信。

Github repository:

  ...
  const messageLog = []
  const attachmentsLog = []
  const listenerMe = (container, msg) => {
    messageLog.push('#me: ' + msg.messageText)
    if (msg.attachments) attachmentsLog.push(...msg.attachments)
  }
  const listenerBot = (container, msg) => {
    messageLog.push('#bot: ' + msg.messageText)
    if (msg.attachments) attachmentsLog.push(...msg.attachments)
  }
  const listenerAttachments = (container, attachment) => {
    attachmentsLog.push(attachment)
  }
  driver.on('MESSAGE_SENTTOBOT', listenerMe)
  driver.on('MESSAGE_RECEIVEDFROMBOT', listenerBot)
  driver.on('MESSAGE_ATTACHMENT', listenerAttachments)
  ...