Class TestLessInputStream
- java.lang.Object
-
- java.io.InputStream
-
- org.apache.maven.plugin.surefire.booterclient.lazytestprovider.AbstractForkInputStream
-
- org.apache.maven.plugin.surefire.booterclient.lazytestprovider.AbstractCommandStream
-
- org.apache.maven.plugin.surefire.booterclient.lazytestprovider.TestLessInputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,NotifiableTestStream
public final class TestLessInputStream extends AbstractCommandStream
Dispatches commands without tests.- Since:
- 2.19
- Author:
- Tibor Digana (tibor17)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TestLessInputStream.TestLessInputStreamBuilder
Buildsstreams
, registers cachable commands and provides accessible API to dispatch immediate commands to all atomically alive streams.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
acknowledgeByeEventReceived()
protected void
beforeNextCommand()
Possibly waiting for next command (seeAbstractCommandStream.nextCommand()
) unless the stream is atomically closed (seeAbstractCommandStream.isClosed()
returnstrue
) before this method has returned.void
close()
protected boolean
isClosed()
protected org.apache.maven.surefire.booter.Command
nextCommand()
void
noop()
void
provideNewTest()
NotifiesTestProvidingInputStream
in order to dispatch a new test back to the forked jvm (particular fork which hits this call); or do nothing inTestLessInputStream
.void
shutdown(org.apache.maven.surefire.booter.Shutdown shutdownType)
void
skipSinceNextTest()
Sends an event to a fork jvm in order to skip tests.-
Methods inherited from class org.apache.maven.plugin.surefire.booterclient.lazytestprovider.AbstractCommandStream
canContinue, invalidateInternalBuffer, read
-
Methods inherited from class org.apache.maven.plugin.surefire.booterclient.lazytestprovider.AbstractForkInputStream
setFlushReceiverProvider, tryFlush
-
-
-
-
Method Detail
-
provideNewTest
public void provideNewTest()
Description copied from interface:NotifiableTestStream
NotifiesTestProvidingInputStream
in order to dispatch a new test back to the forked jvm (particular fork which hits this call); or do nothing inTestLessInputStream
.
-
skipSinceNextTest
public void skipSinceNextTest()
Description copied from interface:NotifiableTestStream
Sends an event to a fork jvm in order to skip tests. Returns immediately without blocking.
-
shutdown
public void shutdown(org.apache.maven.surefire.booter.Shutdown shutdownType)
-
noop
public void noop()
-
acknowledgeByeEventReceived
public void acknowledgeByeEventReceived()
-
isClosed
protected boolean isClosed()
- Specified by:
isClosed
in classAbstractCommandStream
-
nextCommand
protected org.apache.maven.surefire.booter.Command nextCommand()
- Specified by:
nextCommand
in classAbstractCommandStream
-
beforeNextCommand
protected void beforeNextCommand() throws java.io.IOException
Description copied from class:AbstractCommandStream
Possibly waiting for next command (seeAbstractCommandStream.nextCommand()
) unless the stream is atomically closed (seeAbstractCommandStream.isClosed()
returnstrue
) before this method has returned.- Overrides:
beforeNextCommand
in classAbstractCommandStream
- Throws:
java.io.IOException
- stream error while waiting for notification regarding next test required by forked jvm
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Overrides:
close
in classjava.io.InputStream
-
-