Skip to content

[🐛 Bug]: navigateTo should return string or null? #13332

@wlcharlie

Description

@wlcharlie

Have you read the Contributing Guidelines on issues?

WebdriverIO Version

8.39.1

Node.js Version

20.10.0

Mode

Standalone Mode

Which capabilities are you using?

{
  platformName: "mac",
  browserName: "chrome",
  "appium:automationName": "Chromium",
}

What happened?

navigateTo has return type Promise<string> but when it logged null instaed.

image

What is your expected behavior?

should be only just string?
I was using waitUntil and expect return string(or truthy value)

How to reproduce the bug.

driver.waitUntil(
  async () => {
    const returnValue = await driver.navigateTo("<the url>")
    console.log("returnValue:", returnValue)
    return true
  },
  { timeout: 30000 }
)

Relevant log output

console.log
    returnValue: null

      at src/tests/web.test.ts:27:17

Code of Conduct

  • I agree to follow this project's Code of Conduct

Is there an existing issue for this?

  • I have searched the existing issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions