Interface InputStreamTests.MarkResetTests
-
- All Superinterfaces:
InputStreamTests
- Enclosing interface:
- InputStreamTests
@DisplayName("mark(int) and reset()") public static interface InputStreamTests.MarkResetTests extends InputStreamTests
Contains tests forInputStream.mark(int)andInputStream.reset(). Note thatInputStream.markSupported()must be supported.- Author:
- Rob Spoor
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.github.robtimus.junit.support.test.io.InputStreamTests
InputStreamTests.AvailableTests, InputStreamTests.MarkResetTests, InputStreamTests.ReadAllBytesTests, InputStreamTests.ReadByteTests, InputStreamTests.ReadIntoByteArrayPortionTests, InputStreamTests.ReadIntoByteArrayTests, InputStreamTests.ReadNBytesIntoByteArrayPortionTests, InputStreamTests.ReadNBytesTests, InputStreamTests.SkipTests, InputStreamTests.TransferToTests
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default booleanhasDefaultMark()Returns whether or not the input stream to test has an explicit mark at the start of the stream.default voidtestMarkAndReset()default voidtestMarkSupported()default voidtestResetWithoutMark()-
Methods inherited from interface com.github.robtimus.junit.support.test.io.InputStreamTests
expectedContent, inputStream
-
-
-
-
Method Detail
-
hasDefaultMark
default boolean hasDefaultMark()
Returns whether or not the input stream to test has an explicit mark at the start of the stream. If so, thenInputStream.reset()is expected to work without callingInputStream.mark(int)first. Otherwise,InputStream.reset()is expected to fail without callingInputStream.mark(int)first.This default implementation returns
false.- Returns:
trueif the input stream to test has an explicit mark at the start of the stream, orfalseotherwise.
-
testMarkSupported
@Test @DisplayName("markSupported()") default void testMarkSupported()
-
testMarkAndReset
@Test @DisplayName("mark(int) and reset()") default void testMarkAndReset()
-
testResetWithoutMark
@Test @DisplayName("reset() without mark(int)") default void testResetWithoutMark()
-
-