sandwich-webdriver-0.2.3.1: Sandwich integration with Selenium WebDriver
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Sandwich.WebDriver.Internal.Types

Synopsis

Documentation

type Session = String Source #

Session is just a String name.

Labels

type WebDriverContext context wd = (HasLabel context "webdriver" WebDriver, WebDriver (ExampleT context wd)) Source #

class HasWebDriver a where Source #

Instances

Instances details
HasWebDriver WebDriver Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

data WhenToSave Source #

Constructors

Always 
OnException 
Never 

Instances

Instances details
Show WhenToSave Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

Eq WhenToSave Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

data RunMode Source #

Headless and Xvfb modes are useful because they allow you to run tests in the background, without popping up browser windows. This is useful for development or for running on a CI server, and is also more reproducible since the screen resolution can be fixed. In addition, Xvfb mode allows videos to be recorded of tests.

Constructors

Normal

Normal Selenium behavior; will pop up a web browser.

RunHeadless HeadlessConfig

Run with a headless browser. Supports screenshots but videos will be black.

RunInXvfb XvfbConfig

Run inside Xvfb so that tests run in their own X11 display. xvfb-run script must be installed and on the PATH.

data WdOptions Source #

Constructors

WdOptions 

Fields

data SeleniumToUse Source #

How to obtain the Selenium server JAR file.

Constructors

DownloadSeleniumFrom String

Download selenium from the given URL to the toolsRoot

DownloadSeleniumDefault

Download selenium from a default location to the toolsRoot

UseSeleniumAt FilePath

Use the JAR file at the given path

Instances

Instances details
Show SeleniumToUse Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

data ChromeDriverToUse Source #

How to obtain the chromedriver binary.

Constructors

DownloadChromeDriverFrom String

Download chromedriver from the given URL to the toolsRoot

DownloadChromeDriverVersion ChromeDriverVersion

Download the given chromedriver version to the toolsRoot

DownloadChromeDriverAutodetect (Maybe FilePath)

Autodetect chromedriver to use based on the Chrome version and download it to the toolsRoot Pass the path to the Chrome binary, or else it will be found by looking for google-chrome on the PATH.

UseChromeDriverAt FilePath

Use the chromedriver at the given path

data GeckoDriverToUse Source #

How to obtain the geckodriver binary.

Constructors

DownloadGeckoDriverFrom String

Download geckodriver from the given URL to the toolsRoot

DownloadGeckoDriverVersion GeckoDriverVersion

Download the given geckodriver version to the toolsRoot

DownloadGeckoDriverAutodetect (Maybe FilePath)

Autodetect geckodriver to use based on the Gecko version and download it to the toolsRoot Pass the path to the Firefox binary, or else it will be found by looking for firefox on the PATH.

UseGeckoDriverAt FilePath

Use the geckodriver at the given path

newtype ChromeVersion Source #

Constructors

ChromeVersion (Int, Int, Int, Int) 

Instances

Instances details
Show ChromeVersion Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

newtype FirefoxVersion Source #

Constructors

FirefoxVersion (Int, Int, Int) 

Instances

Instances details
Show FirefoxVersion Source # 
Instance details

Defined in Test.Sandwich.WebDriver.Internal.Types

data HeadlessConfig Source #

Constructors

HeadlessConfig 

Fields

defaultHeadlessConfig :: HeadlessConfig Source #

Default headless config.

data XvfbConfig Source #

Constructors

XvfbConfig 

Fields

defaultXvfbConfig :: XvfbConfig Source #

Default Xvfb settings.

defaultWdOptions :: FilePath -> WdOptions Source #

The default WdOptions object. You should start with this and modify it using the accessors.

getWdOptions :: WebDriver -> WdOptions Source #

Get the WdOptions associated with the WebDriver.

getDisplayNumber :: WebDriver -> Maybe Int Source #

Get the X11 display number associated with the WebDriver. Only present if running in RunInXvfb mode.

getXvfbSession :: WebDriver -> Maybe XvfbSession Source #

Get the Xvfb session associated with the WebDriver, if present.

Video stuff

fastX11VideoOptions :: [String] Source #

Default options for fast X11 video recording.

qualityX11VideoOptions :: [String] Source #

Default options for quality X11 video recording.

defaultAvfoundationOptions :: [String] Source #

Default options for AVFoundation recording (for Darwin).

defaultGdigrabOptions :: [String] Source #

Default options for gdigrab recording (for Windows).

data VideoSettings Source #

Constructors

VideoSettings 

Fields

defaultVideoSettings :: VideoSettings Source #

Default video settings.