id_test.go 324 B

1234567891011121314151617
  1. package protocol_test
  2. import (
  3. "testing"
  4. "v2ray.com/core/common/predicate"
  5. . "v2ray.com/core/common/protocol"
  6. "v2ray.com/core/common/uuid"
  7. "v2ray.com/core/testing/assert"
  8. )
  9. func TestCmdKey(t *testing.T) {
  10. assert := assert.On(t)
  11. id := NewID(uuid.New())
  12. assert.Bool(predicate.BytesAll(id.CmdKey(), 0)).IsFalse()
  13. }