2016-02-03 05:58:42 -05:00
|
|
|
package protocol_test
|
2016-01-20 11:45:50 -05:00
|
|
|
|
|
|
|
import (
|
2016-01-21 07:05:16 -05:00
|
|
|
"testing"
|
2016-01-20 11:45:50 -05:00
|
|
|
|
2016-05-24 16:09:22 -04:00
|
|
|
"github.com/v2ray/v2ray-core/common/predicate"
|
2016-02-03 05:58:42 -05:00
|
|
|
. "github.com/v2ray/v2ray-core/common/protocol"
|
2016-01-21 07:05:16 -05:00
|
|
|
"github.com/v2ray/v2ray-core/common/uuid"
|
|
|
|
"github.com/v2ray/v2ray-core/testing/assert"
|
2016-01-20 11:45:50 -05:00
|
|
|
)
|
|
|
|
|
|
|
|
func TestCmdKey(t *testing.T) {
|
2016-05-24 15:55:46 -04:00
|
|
|
assert := assert.On(t)
|
2016-01-20 11:45:50 -05:00
|
|
|
|
2016-01-21 07:05:16 -05:00
|
|
|
id := NewID(uuid.New())
|
2016-05-24 16:09:22 -04:00
|
|
|
assert.Bool(predicate.BytesAll(id.CmdKey(), 0)).IsFalse()
|
2016-01-20 11:45:50 -05:00
|
|
|
}
|