Skip to content

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

Open
@trflynn89

Description

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

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions