mirror of
https://github.com/v2fly/v2ray-core.git
synced 2026-01-05 16:55:27 -05:00
test case for buffer string
This commit is contained in:
@@ -48,3 +48,13 @@ func TestBufferPrepend(t *testing.T) {
|
||||
buffer.Prepend([]byte{'u', 'v', 'w'})
|
||||
assert.Bytes(buffer.Value).Equals([]byte("uvwxyzabc"))
|
||||
}
|
||||
|
||||
func TestBufferString(t *testing.T) {
|
||||
v2testing.Current(t)
|
||||
|
||||
buffer := NewBuffer().Clear()
|
||||
defer buffer.Release()
|
||||
|
||||
buffer.AppendString("Test String")
|
||||
assert.String(buffer).Equals("Test String")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user