Skip to content

Make initialisation consistent for Selenium and non-Selenium drivers #43

@xurizaemon

Description

@xurizaemon

Looking at #30 today I noticed an inconsistency in behaviour (I think).

https://github.com/integratedexperts/behat-screenshot/blob/master/src/IntegratedExperts/BehatScreenshotExtension/Context/ScreenshotContext.php#L73-L92

This checks instanceof Selenium2Driver and fires $driver->start() then does a resize. However, not all drivers that support screenshots are Selenium2Driver (eg DMore/chrome-mink-driver's ChromeDriver.

So ChromeDriver retains resized dimensions between runs (until Chrome exits), while Selenium is consistent. That's not a problem for me - but to implement initial size from behat.yml config in that function for drivers other than Selenium2, we'd need to have that function accommodate those other drivers too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions