aboutsummaryrefslogtreecommitdiff
path: root/args_test.go
diff options
context:
space:
mode:
authorGravatar Aliaksandr Valialkin <valyala@gmail.com> 2016-02-12 14:15:28 +0200
committerGravatar Aliaksandr Valialkin <valyala@gmail.com> 2016-02-12 14:15:28 +0200
commitbfce0fa31c455f52ceb908dbd30e2d86c44ab6fc (patch)
tree37d666672d0136a25cf72ac9ebfe26099d778be9 /args_test.go
parentSwitch from bytes.Buffer to ByteBuffer where appropriate (diff)
downloadfasthttp-bfce0fa31c455f52ceb908dbd30e2d86c44ab6fc.tar.gz
fasthttp-bfce0fa31c455f52ceb908dbd30e2d86c44ab6fc.tar.bz2
fasthttp-bfce0fa31c455f52ceb908dbd30e2d86c44ab6fc.zip
substituted bytes.Buffer by ByteBuffer in tests where appropriate
Diffstat (limited to 'args_test.go')
-rw-r--r--args_test.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/args_test.go b/args_test.go
index e238272..e677677 100644
--- a/args_test.go
+++ b/args_test.go
@@ -1,7 +1,6 @@
package fasthttp
import (
- "bytes"
"fmt"
"strings"
"testing"
@@ -28,7 +27,7 @@ func TestArgsWriteTo(t *testing.T) {
var a Args
a.Parse(s)
- var w bytes.Buffer
+ var w ByteBuffer
n, err := a.WriteTo(&w)
if err != nil {
t.Fatalf("unexpected error: %s", err)
@@ -36,7 +35,7 @@ func TestArgsWriteTo(t *testing.T) {
if n != int64(len(s)) {
t.Fatalf("unexpected n: %d. Expecting %d", n, len(s))
}
- result := string(w.Bytes())
+ result := string(w.B)
if result != s {
t.Fatalf("unexpected result %q. Expecting %q", result, s)
}