public abstract class AbstractDaemonFixture extends java.lang.Object implements DaemonFixture
| Modifier and Type | Field and Description |
|---|---|
org.gradle.launcher.daemon.context.DaemonContext |
context |
static int |
STATE_CHANGE_TIMEOUT |
| Constructor and Description |
|---|
AbstractDaemonFixture(java.io.File daemonLog) |
| Modifier and Type | Method and Description |
|---|---|
void |
assertBusy()
Asserts that this daemon is currently busy.
|
void |
assertCanceled()
Asserts that this daemon is in a canceled state.
|
protected abstract void |
assertHasState(org.gradle.launcher.daemon.server.api.DaemonStateControl.State state) |
void |
assertIdle()
Asserts that this daemon is currently idle.
|
void |
assertStopped()
Asserts that this daemon has stopped and is no longer visible to any clients.
|
void |
becomesCanceled()
Asserts that this daemon becomes canceled within a short timeout.
|
void |
becomesIdle()
Asserts that this daemon becomes idle within a short timeout.
|
org.gradle.launcher.daemon.context.DaemonContext |
getContext()
Returns the context information of this daemon.
|
void |
kill()
Forcefully kills this daemon and all child processes.
|
void |
killDaemonOnly()
Forcefully kills this daemon, but not child processes.
|
boolean |
logContains(long fromLine,
java.lang.String searchString)
Returns whether the log file contains a given String, starting from line `fromLine`
The first line in the file is the line 0.
|
boolean |
logContains(java.lang.String searchString)
Returns whether the log file contains a given String.
|
void |
stops()
Asserts that this daemon stops and is no longer visible to any clients within a short timeout.
|
java.lang.String |
toString() |
protected abstract void |
waitForState(org.gradle.launcher.daemon.server.api.DaemonStateControl.State state) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitassertRegistryNotWorldReadable, changeTokenVisibleToClient, getLog, getLogFile, getPortpublic static final int STATE_CHANGE_TIMEOUT
public final org.gradle.launcher.daemon.context.DaemonContext context
public org.gradle.launcher.daemon.context.DaemonContext getContext()
DaemonFixturegetContext in interface DaemonFixturepublic boolean logContains(java.lang.String searchString)
DaemonFixturelogContains in interface DaemonFixturepublic boolean logContains(long fromLine,
java.lang.String searchString)
DaemonFixturelogContains in interface DaemonFixturepublic void becomesIdle()
DaemonFixturebecomesIdle in interface DaemonFixturepublic void stops()
DaemonFixturestops in interface DaemonFixturepublic void assertIdle()
DaemonFixtureassertIdle in interface DaemonFixturepublic void assertBusy()
DaemonFixtureassertBusy in interface DaemonFixturepublic void assertStopped()
DaemonFixtureassertStopped in interface DaemonFixturepublic void assertCanceled()
DaemonFixtureassertCanceled in interface DaemonFixturepublic void becomesCanceled()
DaemonFixturebecomesCanceled in interface DaemonFixtureprotected abstract void waitForState(org.gradle.launcher.daemon.server.api.DaemonStateControl.State state)
throws java.lang.InterruptedException
java.lang.InterruptedExceptionprotected abstract void assertHasState(org.gradle.launcher.daemon.server.api.DaemonStateControl.State state)
public void kill()
DaemonFixturekill in interface DaemonFixturepublic void killDaemonOnly()
DaemonFixturekillDaemonOnly in interface DaemonFixturepublic java.lang.String toString()
toString in class java.lang.Object