public class SystemPropertiesConfiguration extends java.lang.Object implements Configuration
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_ELEMENT_TIMEOUT_SECONDS
Default timeout when waiting for AJAX elements in pages, in milliseconds.
|
static java.lang.Integer |
DEFAULT_ESTIMATED_AVERAGE_STEP_COUNT |
static java.lang.String |
DEFAULT_WEBDRIVER_DRIVER
The default browser is Firefox.
|
static java.lang.String |
PROJECT_BUILD_DIRECTORY
If in system properties will be defined project.build.directory or project.reporting.OutputDirectory then it will
be used for output for serenity test reports.
|
static java.lang.String |
REFUSE_UNTRUSTED_CERTIFICATES
By default, when accepting untrusted SSL certificates, assume that these certificates will come from an
untrusted issuer or will be self signed.
|
Constructor and Description |
---|
SystemPropertiesConfiguration(EnvironmentVariables environmentVariables) |
Modifier and Type | Method and Description |
---|---|
Configuration |
copy() |
java.lang.String |
getBaseUrl()
This is the URL where test cases start.
|
int |
getCurrentTestCount()
This is the URL where test cases start.
|
SupportedWebDriver |
getDriverType()
Get the currently-configured browser type.
|
int |
getElementTimeout() |
EnvironmentVariables |
getEnvironmentVariables() |
double |
getEstimatedAverageStepCount() |
java.io.File |
getHistoryDirectory() |
java.io.File |
getOutputDirectory()
The output directory is where the test runner writes the XML and HTML
reports to.
|
int |
getRestartFrequency() |
com.google.common.base.Optional<TakeScreenshots> |
getScreenshotLevel()
How often should screenshots be taken.
|
int |
getStepDelay() |
boolean |
getUseUniqueBrowser()
Use shouldUseAUniqueBrowser() instead
|
java.io.File |
loadHistoryDirectoryFromSystemProperties() |
java.io.File |
loadOutputDirectoryFromSystemProperties()
Where should the reports go?
|
boolean |
onlySaveFailingScreenshots() |
void |
reloadOutputDirectory()
If some property that can change output directory was changed this method should be called
|
void |
setDefaultBaseUrl(java.lang.String defaultBaseUrl)
Override the default base URL manually.
|
void |
setIfUndefined(java.lang.String property,
java.lang.String value) |
void |
setOutputDirectory(java.io.File outputDirectory) |
boolean |
shouldUseAUniqueBrowser() |
boolean |
takeVerboseScreenshots()
Take a screenshot for each action.
|
Configuration |
withEnvironmentVariables(EnvironmentVariables environmentVariables) |
public static final java.lang.String DEFAULT_WEBDRIVER_DRIVER
public static final int DEFAULT_ELEMENT_TIMEOUT_SECONDS
public static final java.lang.Integer DEFAULT_ESTIMATED_AVERAGE_STEP_COUNT
public static final java.lang.String PROJECT_BUILD_DIRECTORY
public static final java.lang.String REFUSE_UNTRUSTED_CERTIFICATES
@Inject public SystemPropertiesConfiguration(EnvironmentVariables environmentVariables)
public Configuration copy()
copy
in interface Configuration
public Configuration withEnvironmentVariables(EnvironmentVariables environmentVariables)
withEnvironmentVariables
in interface Configuration
public EnvironmentVariables getEnvironmentVariables()
getEnvironmentVariables
in interface Configuration
public SupportedWebDriver getDriverType()
getDriverType
in interface Configuration
public java.io.File loadOutputDirectoryFromSystemProperties()
public java.io.File loadHistoryDirectoryFromSystemProperties()
public void reloadOutputDirectory()
public int getStepDelay()
getStepDelay
in interface Configuration
public int getElementTimeout()
getElementTimeout
in interface Configuration
public boolean getUseUniqueBrowser()
Configuration
getUseUniqueBrowser
in interface Configuration
public boolean shouldUseAUniqueBrowser()
shouldUseAUniqueBrowser
in interface Configuration
public void setOutputDirectory(java.io.File outputDirectory)
setOutputDirectory
in interface Configuration
public java.io.File getOutputDirectory()
getOutputDirectory
in interface Configuration
public java.io.File getHistoryDirectory()
getHistoryDirectory
in interface Configuration
public double getEstimatedAverageStepCount()
getEstimatedAverageStepCount
in interface Configuration
public boolean onlySaveFailingScreenshots()
onlySaveFailingScreenshots
in interface Configuration
public boolean takeVerboseScreenshots()
Configuration
takeVerboseScreenshots
in interface Configuration
public com.google.common.base.Optional<TakeScreenshots> getScreenshotLevel()
Configuration
getScreenshotLevel
in interface Configuration
public void setIfUndefined(java.lang.String property, java.lang.String value)
setIfUndefined
in interface Configuration
public void setDefaultBaseUrl(java.lang.String defaultBaseUrl)
setDefaultBaseUrl
in interface Configuration
public int getRestartFrequency()
getRestartFrequency
in interface Configuration
public int getCurrentTestCount()
Configuration
getCurrentTestCount
in interface Configuration
public java.lang.String getBaseUrl()
getBaseUrl
in interface Configuration