mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Update utils_test.go
This commit is contained in:
parent
822cf67dae
commit
10f5b6486c
1 changed files with 3 additions and 3 deletions
|
@ -10,7 +10,7 @@ import (
|
|||
|
||||
func TestBufReader(t *testing.T) {
|
||||
reader, writer := io.Pipe()
|
||||
bufreader := newBufReader(reader)
|
||||
bufreader := NewBufReader(reader)
|
||||
|
||||
// Write everything down to a Pipe
|
||||
// Usually, a pipe should block but because of the buffered reader,
|
||||
|
@ -55,7 +55,7 @@ func (dw *dummyWriter) Close() error {
|
|||
}
|
||||
|
||||
func TestWriteBroadcaster(t *testing.T) {
|
||||
writer := newWriteBroadcaster()
|
||||
writer := NewWriteBroadcaster()
|
||||
|
||||
// Test 1: Both bufferA and bufferB should contain "foo"
|
||||
bufferA := &dummyWriter{}
|
||||
|
@ -137,7 +137,7 @@ func (d devNullCloser) Write(buf []byte) (int, error) {
|
|||
|
||||
// This test checks for races. It is only useful when run with the race detector.
|
||||
func TestRaceWriteBroadcaster(t *testing.T) {
|
||||
writer := newWriteBroadcaster()
|
||||
writer := NewWriteBroadcaster()
|
||||
c := make(chan bool)
|
||||
go func() {
|
||||
writer.AddWriter(devNullCloser(0))
|
||||
|
|
Loading…
Reference in a new issue