Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestReaderSimple (0.27 sec)

  1. src/bufio/bufio_test.go

    		if err == io.EOF {
    			break
    		}
    		if err == nil {
    			b[nb] = c
    			nb++
    		} else if err != iotest.ErrTimeout {
    			panic("Data: " + err.Error())
    		}
    	}
    	return string(b[0:nb])
    }
    
    func TestReaderSimple(t *testing.T) {
    	data := "hello world"
    	b := NewReader(strings.NewReader(data))
    	if s := readBytes(b); s != "hello world" {
    		t.Errorf("simple hello world test failed: got %q", s)
    	}
    
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Feb 10 18:56:01 GMT 2023
    - 51.5K bytes
    - Viewed (0)
Back to top