我是黄瓜/硒新手,正在测试用户登陆网页时的情况。我被抛出此错误...当我删除承诺时,它会起作用。
startPromise.then(function () {
Given('User lands on {string}', async function (url) {
await this.driver.get(url);
});
}).then(function () {
// more code
这引发了错误
(node:6228) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'push' of undefined
test.feature
Scenario: Test
Given User lands on "https://www.google.com"