Skip to content

Problem reading --variables from pytest.ini if --driver-path specified #105

@birdsarah

Description

@birdsarah

Not sure how best to investigate this or if this is even a pytest selenium problem.

On Windows 10.

I have a pytest.ini file

[pytest]
addopts = --variables=variables.json

If I run the following (with chromedriver available on the path):

$ py.test --base-url www.google.com --driver Chrome

Then the variables.json is picked up correctly.

However, if I run the following:

$ py.test --base-url www.google.com --driver Chrome --driver-path ..\..\..\WebDrivers\chromedriver.exe

Then variables.json is not picked up for the variables option.

Finally though, if I add --variables variables.json into the call then it does work:

$ py.test --base-url www.google.com --driver Chrome --driver-path ..\..\..\WebDrivers\chromedriver.exe --variables variables.json

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions