Skip to content

fix: polish isStable commands#14745

Merged
christian-bromann merged 1 commit intomainfrom
ws/is-statble-native-fix
Sep 9, 2025
Merged

fix: polish isStable commands#14745
christian-bromann merged 1 commit intomainfrom
ws/is-statble-native-fix

Conversation

@wswebcreation
Copy link
Member

Proposed changes

This change will make sure it throws an error for native apps

Types of changes

  • Polish (an improvement for an existing feature)
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update (improvements to the project's docs)
  • Specification changes (updates to WebDriver command specifications)
  • Internal updates (everything related to internal scripts, governance documentation and CI files)

Checklist

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have added the necessary documentation (if appropriate)
  • I have added proper type definitions for new commands (if appropriate)

Backport Request

//: # (The current main branch is the development branch for WebdriverIO v9. If your change should be released to the current major version of WebdriverIO (v8), please raise another PR with the same changes against the v8 branch.)

  • This change is solely for v9 and doesn't need to be back-ported
  • Back-ported PR at #XXXXX

Further comments

Reviewers: @webdriverio/project-committers

@wswebcreation wswebcreation added the PR: Polish 💅 PRs that contain improvements on existing features label Sep 6, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds error handling to prevent isStable and waitForStable commands from being executed in native mobile app contexts, where they are not supported. The change ensures these commands throw clear error messages when used inappropriately.

  • Added native context validation to both isStable and waitForStable commands
  • Updated documentation to clarify browser-only availability
  • Added comprehensive tests to verify error handling for native contexts

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
packages/webdriverio/src/commands/element/isStable.ts Added native context check and updated documentation
packages/webdriverio/src/commands/element/waitForStable.ts Added native context check and updated documentation
packages/webdriverio/tests/commands/element/isStable.test.ts Added test case for native context error handling
packages/webdriverio/tests/commands/element/waitForStable.test.ts Added test case for native context error handling

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Member

@christian-bromann christian-bromann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@christian-bromann christian-bromann merged commit d64d594 into main Sep 9, 2025
63 of 64 checks passed
@christian-bromann christian-bromann deleted the ws/is-statble-native-fix branch September 9, 2025 01:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: Polish 💅 PRs that contain improvements on existing features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants