1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-09-27 22:36:12 -04:00

remove unnecessary test

This commit is contained in:
Darien Raymond 2018-04-01 09:51:44 +02:00
parent 6d98bc4607
commit 50c4e3389c
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169

View File

@ -5,7 +5,6 @@ import (
"io"
"testing"
"v2ray.com/core/app/stats"
"v2ray.com/core/common/buf"
. "v2ray.com/core/transport/ray"
. "v2ray.com/ext/assert"
@ -48,18 +47,3 @@ func TestStreamClose(t *testing.T) {
_, err = stream.ReadMultiBuffer()
assert(err, Equals, io.EOF)
}
func TestStreamStatCounter(t *testing.T) {
assert := With(t)
c := new(stats.Counter)
stream := NewStream(context.Background(), WithStatCounter(c))
b1 := buf.New()
b1.AppendBytes('a', 'b', 'c', 'd')
assert(stream.WriteMultiBuffer(buf.NewMultiBufferValue(b1)), IsNil)
stream.Close()
assert(c.Value(), Equals, int64(4))
}