1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2025-12-27 20:45:28 -05:00

refine ctlcmd

This commit is contained in:
Darien Raymond
2018-04-13 13:54:36 +02:00
parent 48e825567a
commit f751bb610c
3 changed files with 63 additions and 49 deletions

View File

@@ -2,6 +2,7 @@ package buf_test
import (
"crypto/rand"
"io"
"testing"
"v2ray.com/core/common"
@@ -48,3 +49,10 @@ func TestMultiBufferSliceBySizeLarge(t *testing.T) {
mb2 := mb.SliceBySize(4 * 1024)
assert(mb2.Len(), Equals, int32(4*1024))
}
func TestInterface(t *testing.T) {
assert := With(t)
assert((*MultiBuffer)(nil), Implements, (*io.WriterTo)(nil))
assert((*MultiBuffer)(nil), Implements, (*io.ReaderFrom)(nil))
}