diff --git a/seekbuf/seekbuf_test.go b/seekbuf/seekbuf_test.go index e64296a..d840fbc 100644 --- a/seekbuf/seekbuf_test.go +++ b/seekbuf/seekbuf_test.go @@ -1,18 +1,20 @@ -package seekbuf +package seekbuf_test import ( "fmt" "testing" "git.wntrmute.dev/kyle/goutils/assert" + "git.wntrmute.dev/kyle/goutils/seekbuf" ) func TestSeeking(t *testing.T) { partA := []byte("hello, ") partB := []byte("world!") - buf := New(partA) - assert.BoolT(t, buf.Len() == len(partA), fmt.Sprintf("on init: have length %d, want length %d", buf.Len(), len(partA))) + buf := seekbuf.New(partA) + assert.BoolT(t, buf.Len() == len(partA), + fmt.Sprintf("on init: have length %d, want length %d", buf.Len(), len(partA))) b := make([]byte, 32) @@ -32,7 +34,8 @@ func TestSeeking(t *testing.T) { partsLen := len(partA) + len(partB) buf.Rewind() - assert.BoolT(t, buf.Len() == partsLen, fmt.Sprintf("after rewinding: have length %d, want length %d", buf.Len(), partsLen)) + assert.BoolT(t, buf.Len() == partsLen, + fmt.Sprintf("after rewinding: have length %d, want length %d", buf.Len(), partsLen)) buf.Close() assert.BoolT(t, buf.Len() == 0, fmt.Sprintf("after closing, have length %d, want length 0", buf.Len()))