Giter Club home page Giter Club logo

Comments (7)

whimboo avatar whimboo commented on June 12, 2024

Matching on our side takes place as:

https://searchfox.org/mozilla-central/rev/9e5b13e92b50c61e60a42bdc2cb2e5966ae28795/remote/shared/webdriver/Capabilities.sys.mjs#560-573

Note scenarios like window manipulation tests that want to position or resize browser windows. If you would run these tests on desktop it should basically work in nearly all the cases (exception would be Wayland) but on Android it should basically fail.

With matching clients can request that this feature is present to actually run all the tests on that given platform and if it's not supported the session will not be created.

wpt.fyi shows the difference between Firefox on Android and Chrome on Android. For Chrome an assertion only fails without any details that the command actually doesn't work, while for Firefox an unsupported operation is raised.

With matching the capability we would get a clear failure right in New Session for all browsers.

from webdriver.

OrKoN avatar OrKoN commented on June 12, 2024

Chrome does not do matching for this capability and it is a return-only value: https://source.chromium.org/chromium/chromium/src/+/main:chrome/test/chromedriver/session_commands.cc;l=189;drc=21802bc29a3f1f96a333bc52039dc56764a85524 (it will reject the property as invalid argument if it is in the capabilities request)

from webdriver.

whimboo avatar whimboo commented on June 12, 2024

@shs96c @AutomatedTester @titusfortner @jimevans from the Selenium side of view how would you expect a remote end to behave when it doesn't support window manipulation? Should matching the setWindowRect capability fail if it's value in the requested capabilities is set to true? Or would you expect all the tests trying to manipulate the window to fail because the requested operation cannot be achieved?

from webdriver.

gsnedders avatar gsnedders commented on June 12, 2024

It likewise is return-only in safaridriver.

(Despite being the OP, I was just doing what the action item from the meeting said; I don't have any particularly strong opinion on whether we should make it possible to match on it.)

from webdriver.

jimevans avatar jimevans commented on June 12, 2024

Generally speaking, Selenium expects that capability to be return-only. I don’t know of anyone attempting to match on that capability in the Selenium world.

from webdriver.

whimboo avatar whimboo commented on June 12, 2024

Given that matching is not expected should we close the issue? Or should we try to match all known and supported capabilities?

from webdriver.

titusfortner avatar titusfortner commented on June 12, 2024

I've never understood why it was there in the first place. πŸ˜‚

My philosophy is that your test should already have all the information it needs to execute a deterministic test, and it shouldn't be toggling the action to take based on the returned capabilities, so it shouldn't need to be something that gets returned, let alone set, but that's my opinion.

That said, if the spec says these need to be matching, do we at least need to change the spec language?

from webdriver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.