Commit 26a2642f authored by Russ Cox's avatar Russ Cox

fix codec test bug - uint -> uint8

R=r
OCL=33913
CL=33913
parent 06cac23d
...@@ -168,7 +168,7 @@ func TestScalarEncInstructions(t *testing.T) { ...@@ -168,7 +168,7 @@ func TestScalarEncInstructions(t *testing.T) {
{ {
b.Reset(); b.Reset();
data := struct { a int8 } { 17 }; data := struct { a int8 } { 17 };
instr := &encInstr{ encInt, 6, 0, 0 }; instr := &encInstr{ encInt8, 6, 0, 0 };
state := newencoderState(b); state := newencoderState(b);
instr.op(instr, state, unsafe.Pointer(&data)); instr.op(instr, state, unsafe.Pointer(&data));
if !bytes.Equal(signedResult, b.Data()) { if !bytes.Equal(signedResult, b.Data()) {
...@@ -180,7 +180,7 @@ func TestScalarEncInstructions(t *testing.T) { ...@@ -180,7 +180,7 @@ func TestScalarEncInstructions(t *testing.T) {
{ {
b.Reset(); b.Reset();
data := struct { a uint8 } { 17 }; data := struct { a uint8 } { 17 };
instr := &encInstr{ encUint, 6, 0, 0 }; instr := &encInstr{ encUint8, 6, 0, 0 };
state := newencoderState(b); state := newencoderState(b);
instr.op(instr, state, unsafe.Pointer(&data)); instr.op(instr, state, unsafe.Pointer(&data));
if !bytes.Equal(unsignedResult, b.Data()) { if !bytes.Equal(unsignedResult, b.Data()) {
...@@ -255,7 +255,7 @@ func TestScalarEncInstructions(t *testing.T) { ...@@ -255,7 +255,7 @@ func TestScalarEncInstructions(t *testing.T) {
{ {
b.Reset(); b.Reset();
data := struct { a uint64 } { 17 }; data := struct { a uint64 } { 17 };
instr := &encInstr{ encUint, 6, 0, 0 }; instr := &encInstr{ encUint64, 6, 0, 0 };
state := newencoderState(b); state := newencoderState(b);
instr.op(instr, state, unsafe.Pointer(&data)); instr.op(instr, state, unsafe.Pointer(&data));
if !bytes.Equal(unsignedResult, b.Data()) { if !bytes.Equal(unsignedResult, b.Data()) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment