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 Pattern
CYPRESS_VERSION_PATTERN
static String
DEFAULT_CYPRESS_VERSION
static String
RUNNER_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 void
close()
ExecutionReport
execute(String command, long commandTimeout)
String
getId()
protected String
getNextCommand()
protected void
onCypressStarted()
protected void
reportExecution(ExecutionReport report)
protected void
start(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:
InterruptedException
ch.exense.commons.processes.ManagedProcess.ManagedProcessException
IOException
-
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:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
-