Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing "invalid" timeouts configurations in /webdriver/tests/classic/new_session/invalid_capabilities.py #50573

Open
trflynn89 opened this issue Feb 7, 2025 · 1 comment

Comments

@trflynn89
Copy link

trflynn89 commented Feb 7, 2025

This test checks that the following timeouts configuration objects are rejected when creating a new session:

("timeouts", [
    1, [], "{}", False,
    {"invalid": 10},
    {"PAGELOAD": 10},
    {"page load": 10},
    {" pageLoad": 10},
    {"pageLoad ": 10},
    {"pageLoad": None},
    {"pageLoad": False},
    {"pageLoad": []},
    {"pageLoad": "10"},
    {"pageLoad": 2.5},
    {"pageLoad": -1},
    {"pageLoad": 2**53},
    {"pageLoad": {"value": 10}},
    {"pageLoad": 10, "invalid": 10},
]),

I had two questions about this data:

  1. It seems that {"pageLoad": None} should not be rejected. The WebDriver spec now explicitly allows null timeout values. Is this right?
  2. Should the presence of keys such as "invalid", "PAGELOAD", etc. actually be rejected? The timeouts deserialization steps explictly says to just ignore unknown keys. rather than returning an error:
    https://w3c.github.io/webdriver/#dfn-deserialize-as-timeouts-configuration
3. For each key → value in timeouts:
    1. If «"script", "pageLoad", "implicit"» does not contain key, then continue.

/webdriver/tests/classic/new_session/timeouts.py seems to have the same issue as (1) above, in that it is expecting null timeout values to be rejected

@Classicrichblog
Copy link

Implement for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants