Searched refs:TestByteSource (Results 1 – 8 of 8) sorted by relevance
/external/guava/guava-tests/test/com/google/common/io/ |
D | ByteSourceTest.java | 70 private TestByteSource source; 74 source = new TestByteSource(bytes); in setUp() 96 assertEquals(bytes.length, new TestByteSource(bytes, SKIP_THROWS).size()); in testSize() 99 assertEquals(bytes.length, new TestByteSource(bytes, AVAILABLE_ALWAYS_ZERO).size()); in testSize() 176 ByteSource byteSource = new TestByteSource("hamburger\n".getBytes(Charsets.US_ASCII)); in testHash() 186 ByteSource equalSource = new TestByteSource(bytes); in testContentEquals() 188 assertTrue(new TestByteSource(bytes).contentEquals(source)); in testContentEquals() 190 ByteSource fewerBytes = new TestByteSource(newPreFilledByteArray(bytes.length / 2)); in testContentEquals() 195 ByteSource oneByteOff = new TestByteSource(copy); in testContentEquals() 306 ByteSource source = new TestByteSource(newPreFilledByteArray(input)); in assertCorrectSlice() [all …]
|
D | ByteSinkTest.java | 83 TestByteSource failSource = new TestByteSource(new byte[10], option); in testClosesOnErrors_copyingFromByteSourceThatThrows() 101 new TestByteSource(new byte[10]).copyTo(failSink); in testClosesOnErrors_whenWriteThrows()
|
D | TestCharSource.java | 32 private final TestByteSource byteSource; 35 this.byteSource = new TestByteSource(content.getBytes(UTF_8), options); in TestCharSource()
|
D | TestByteSource.java | 32 public final class TestByteSource extends ByteSource implements TestStreamSupplier { class 40 TestByteSource(byte[] bytes, TestOption... options) { in TestByteSource() method in TestByteSource
|
/external/guava/android/guava-tests/test/com/google/common/io/ |
D | ByteSourceTest.java | 70 private TestByteSource source; 74 source = new TestByteSource(bytes); in setUp() 96 assertEquals(bytes.length, new TestByteSource(bytes, SKIP_THROWS).size()); in testSize() 99 assertEquals(bytes.length, new TestByteSource(bytes, AVAILABLE_ALWAYS_ZERO).size()); in testSize() 176 ByteSource byteSource = new TestByteSource("hamburger\n".getBytes(Charsets.US_ASCII)); in testHash() 186 ByteSource equalSource = new TestByteSource(bytes); in testContentEquals() 188 assertTrue(new TestByteSource(bytes).contentEquals(source)); in testContentEquals() 190 ByteSource fewerBytes = new TestByteSource(newPreFilledByteArray(bytes.length / 2)); in testContentEquals() 195 ByteSource oneByteOff = new TestByteSource(copy); in testContentEquals() 306 ByteSource source = new TestByteSource(newPreFilledByteArray(input)); in assertCorrectSlice() [all …]
|
D | ByteSinkTest.java | 83 TestByteSource failSource = new TestByteSource(new byte[10], option); in testClosesOnErrors_copyingFromByteSourceThatThrows() 101 new TestByteSource(new byte[10]).copyTo(failSink); in testClosesOnErrors_whenWriteThrows()
|
D | TestCharSource.java | 32 private final TestByteSource byteSource; 35 this.byteSource = new TestByteSource(content.getBytes(UTF_8), options); in TestCharSource()
|
D | TestByteSource.java | 32 public final class TestByteSource extends ByteSource implements TestStreamSupplier { class 40 TestByteSource(byte[] bytes, TestOption... options) { in TestByteSource() method in TestByteSource
|