Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for TestReader (0.05 sec)

  1. android/guava-tests/test/com/google/common/io/CharSinkTest.java

        assertTrue(sink.wasStreamOpened() && sink.wasStreamClosed());
        assertEquals(STRING, sink.getString());
      }
    
      public void testWriteFromStream_doesNotCloseThatStream() throws IOException {
        TestReader in = new TestReader();
        assertFalse(in.closed());
        sink.writeFrom(in);
        assertFalse(in.closed());
      }
    
      public void testWriteLines_withSpecificSeparator() throws IOException {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 31 14:20:11 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  2. src/bufio/bufio_test.go

    var testInputrn = []byte("012\r\n345\r\n678\r\n9ab\r\ncde\r\nfgh\r\nijk\r\nlmn\r\nopq\r\nrst\r\nuvw\r\nxy\r\n\n\r\n")
    
    // TestReader wraps a []byte and returns reads of a specific length.
    type testReader struct {
    	data   []byte
    	stride int
    }
    
    func (t *testReader) Read(buf []byte) (n int, err error) {
    	n = t.stride
    	if n > len(t.data) {
    		n = len(t.data)
    	}
    	if n > len(buf) {
    		n = len(buf)
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Fri Nov 01 21:52:12 UTC 2024
    - 51.6K bytes
    - Viewed (0)
Back to top