在<csselement>上运行.getAttribute()命令时发生错误:TypeError:_this2.client.assertion不是函数

时间:2018-05-15 14:49:25

标签: node.js nightwatch.js

在创建夜班测试时,我使用了waitForAttribute(),它适用于nightwatch@0.9.0。但是当我尝试升级到nightwatch@1.0.6时,它会出现以下错误:

An error occurred while running .getAttribute() command on <.csselement>: TypeError: _this2.client.assertion is not a function
  at /node_modules/nightwatch-custom-commands-assertions/js/commands/waitForAttribute.js:100:19
  at NightwatchAPI.<anonymous> (.../node_modules/nightwatch-custom-commands-assertions/js/commands/waitForAttribute.js:117:13)
  at transport.locateElement.then.then.result (../node_modules/nightwatch/lib/api-loader/element-command.js:107:23)
  at <anonymous>
  at process._tickCallback (internal/process/next_tick.js:188:7)
   at <anonymous>
   at process._tickCallback (internal/process/next_tick.js:188:7)
   at <anonymous>
   at process._tickCallback (internal/process/next_tick.js:188:7)

0 个答案:

没有答案