Package com.vaadin.testbench.screenshot
Class ReferenceNameGenerator
java.lang.Object
com.vaadin.testbench.screenshot.ReferenceNameGenerator
Generates the name of a reference screen shot from a string ID and browser
information.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongenerateName
(String referenceId, org.openqa.selenium.Capabilities browserCapabilities) Generates the actual name of a reference screen shot from a reference ID and browser information.static String
getMajorVersion
(org.openqa.selenium.Capabilities browserCapabilities) Finds the major version by parsing the browser version string.
-
Constructor Details
-
ReferenceNameGenerator
public ReferenceNameGenerator()
-
-
Method Details
-
generateName
public String generateName(String referenceId, org.openqa.selenium.Capabilities browserCapabilities) Generates the actual name of a reference screen shot from a reference ID and browser information.- Parameters:
referenceId
- the reference IDbrowserCapabilities
- aCapabilities
instance containing information on the browser.- Returns:
- The actual name.
-
getMajorVersion
Finds the major version by parsing the browser version string.- Parameters:
browserCapabilities
- the capabilities object holding the version information- Returns:
- the major version of the browser.
-