1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-12-22 18:17:52 -05:00
This commit is contained in:
Darien Raymond 2017-05-04 19:55:02 +02:00
commit 5dbfd75542
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169

View File

@ -644,14 +644,14 @@ func TestVMessNone(t *testing.T) {
}) })
assert.Error(err).IsNil() assert.Error(err).IsNil()
payload := make([]byte, 10240*1024) payload := make([]byte, 1024*1024)
rand.Read(payload) rand.Read(payload)
nBytes, err := conn.Write(payload) nBytes, err := conn.Write(payload)
assert.Error(err).IsNil() assert.Error(err).IsNil()
assert.Int(nBytes).Equals(len(payload)) assert.Int(nBytes).Equals(len(payload))
response := readFrom(conn, time.Second*20, 10240*1024) response := readFrom(conn, time.Second*20, 1024*1024)
assert.Bytes(response).Equals(xor(payload)) assert.Bytes(response).Equals(xor(payload))
assert.Error(conn.Close()).IsNil() assert.Error(conn.Close()).IsNil()
wg.Done() wg.Done()