Package step.plugins.cypress
Class CypressSession
- java.lang.Object
-
- step.plugins.cypress.CypressSession
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class CypressSession extends Object implements Closeable
-
-
Field Summary
Fields Modifier and Type Field Description static PatternCYPRESS_VERSION_PATTERNstatic StringDEFAULT_CYPRESS_VERSIONstatic StringRUNNER_SPEC_LOCATION_9
-
Constructor Summary
Constructors Constructor Description CypressSession(CypressSessionManager cypressSessionManager, File projectFile)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()ExecutionReportexecute(String command, long commandTimeout)StringgetId()protected StringgetNextCommand()protected voidonCypressStarted()protected voidreportExecution(ExecutionReport report)protected voidstart(boolean takeScreenshots, boolean headless, String baseUrl)
-
-
-
Field Detail
-
CYPRESS_VERSION_PATTERN
public static final Pattern CYPRESS_VERSION_PATTERN
-
DEFAULT_CYPRESS_VERSION
public static final String DEFAULT_CYPRESS_VERSION
- See Also:
- Constant Field Values
-
RUNNER_SPEC_LOCATION_9
public static final String RUNNER_SPEC_LOCATION_9
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CypressSession
public CypressSession(CypressSessionManager cypressSessionManager, File projectFile)
-
-
Method Detail
-
start
protected void start(boolean takeScreenshots, boolean headless, String baseUrl) throws InterruptedException, ch.exense.commons.processes.ManagedProcess.ManagedProcessException, IOException- Throws:
InterruptedExceptionch.exense.commons.processes.ManagedProcess.ManagedProcessExceptionIOException
-
getId
public String getId()
-
execute
public ExecutionReport execute(String command, long commandTimeout) throws InterruptedException
- Throws:
InterruptedException
-
onCypressStarted
protected void onCypressStarted()
-
reportExecution
protected void reportExecution(ExecutionReport report)
-
getNextCommand
protected String getNextCommand() throws InterruptedException
- Throws:
InterruptedException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
-