add tuples tests

This commit is contained in:
Neemek 2026-07-11 12:51:39 +02:00
parent e03d18c7db
commit 94b12f28ab
Signed by: neemek
GPG key ID: 84FFE4D7D40AB25E
3 changed files with 101 additions and 101 deletions

View file

@ -2,6 +2,7 @@ package core
import (
"fmt"
"math/big"
"testing"
)
@ -615,6 +616,28 @@ func GetExecutionTestData() map[string]struct {
},
[]map[string]Value{},
},
"form_tuple": {
&Chunk{
Bytecode: []Bytecode{
InstructionConstant, 0,
InstructionConstant, 1,
InstructionFormTuple, 0, 2,
},
Constants: []Value{
&IntegerValue{big.NewInt(1)},
&IntegerValue{big.NewInt(2)},
},
},
[]Value{
&TupleValue{
Items: []Value{
&IntegerValue{big.NewInt(1)},
&IntegerValue{big.NewInt(2)},
},
},
},
[]map[string]Value{},
},
}
}