fix tree for reflect rename
R=golang-dev, r CC=golang-dev https://golang.org/cl/4435067
This commit is contained in:
parent
c282fa0f0b
commit
f23d109356
@ -32,7 +32,7 @@ type testMessage interface {
|
|||||||
func TestMarshalUnmarshal(t *testing.T) {
|
func TestMarshalUnmarshal(t *testing.T) {
|
||||||
rand := rand.New(rand.NewSource(0))
|
rand := rand.New(rand.NewSource(0))
|
||||||
for i, iface := range tests {
|
for i, iface := range tests {
|
||||||
ty := reflect.NewValue(iface).Type()
|
ty := reflect.ValueOf(iface).Type()
|
||||||
|
|
||||||
n := 100
|
n := 100
|
||||||
if testing.Short() {
|
if testing.Short() {
|
||||||
@ -125,7 +125,7 @@ func (*clientHelloMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
|||||||
m.supportedCurves[i] = uint16(rand.Intn(30000))
|
m.supportedCurves[i] = uint16(rand.Intn(30000))
|
||||||
}
|
}
|
||||||
|
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*serverHelloMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*serverHelloMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
@ -146,7 +146,7 @@ func (*serverHelloMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*certificateMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*certificateMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
@ -156,7 +156,7 @@ func (*certificateMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
|||||||
for i := 0; i < numCerts; i++ {
|
for i := 0; i < numCerts; i++ {
|
||||||
m.certificates[i] = randomBytes(rand.Intn(10)+1, rand)
|
m.certificates[i] = randomBytes(rand.Intn(10)+1, rand)
|
||||||
}
|
}
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*certificateRequestMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*certificateRequestMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
@ -167,13 +167,13 @@ func (*certificateRequestMsg) Generate(rand *rand.Rand, size int) reflect.Value
|
|||||||
for i := 0; i < numCAs; i++ {
|
for i := 0; i < numCAs; i++ {
|
||||||
m.certificateAuthorities[i] = randomBytes(rand.Intn(15)+1, rand)
|
m.certificateAuthorities[i] = randomBytes(rand.Intn(15)+1, rand)
|
||||||
}
|
}
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*certificateVerifyMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*certificateVerifyMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
m := &certificateVerifyMsg{}
|
m := &certificateVerifyMsg{}
|
||||||
m.signature = randomBytes(rand.Intn(15)+1, rand)
|
m.signature = randomBytes(rand.Intn(15)+1, rand)
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*certificateStatusMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*certificateStatusMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
@ -184,23 +184,23 @@ func (*certificateStatusMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
|||||||
} else {
|
} else {
|
||||||
m.statusType = 42
|
m.statusType = 42
|
||||||
}
|
}
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*clientKeyExchangeMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*clientKeyExchangeMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
m := &clientKeyExchangeMsg{}
|
m := &clientKeyExchangeMsg{}
|
||||||
m.ciphertext = randomBytes(rand.Intn(1000)+1, rand)
|
m.ciphertext = randomBytes(rand.Intn(1000)+1, rand)
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*finishedMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*finishedMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
m := &finishedMsg{}
|
m := &finishedMsg{}
|
||||||
m.verifyData = randomBytes(12, rand)
|
m.verifyData = randomBytes(12, rand)
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (*nextProtoMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
func (*nextProtoMsg) Generate(rand *rand.Rand, size int) reflect.Value {
|
||||||
m := &nextProtoMsg{}
|
m := &nextProtoMsg{}
|
||||||
m.proto = randomString(rand.Intn(255), rand)
|
m.proto = randomString(rand.Intn(255), rand)
|
||||||
return reflect.NewValue(m)
|
return reflect.ValueOf(m)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user