typescript - 对于打字稿中的黄瓜数据表,始终返回 true
问题描述
即使对于 dataTable 中的错误数据,以下步骤定义也始终返回 true。
你能帮我用 chai 断言纠正打字稿中的语法吗?
Then(/^Verify the following details in report$/, async (table: TableDefinition) => {
table.rows().forEach(row => {
return expect(homepage.getDamagedPartyName()).to.eventually.equal(row[0]);
});
});
解决方案
我希望问题出在 return 关键字上。删除 return 并尝试如下所示:
期望(homepage.getDamagedPartyName()).to.equal(row[0]);
推荐阅读
- java - @ColumnTransformer 未在选择中使用
- sharepoint-2013 - 如何使用 REST 在 SharePoint 2013 设计器中循环访问多值人员字段或查找字段
- google-cloud-platform - 数据集未加载
- identityserver4 - 这是从强命名的 .NET DLL 引用 Thinktecture DLL 的好方法吗?
- ruby - 迭代器这部分的 Ruby 术语是什么?
- python-3.x - 我可以将 scipy.optimize 与 numpy.where 一起使用吗?
- ldap - 冗余负载平衡 LDAP 组的 Freeradius 问题
- c++ - 将 Eigen::MatrixXd(m,n) 与 1x1 矩阵相乘
- java - Appium - 无法访问 hideKeyboard() 方法
- nuxt.js - 为什么它显示请求失败,状态码为 401?