5 func TestEncodeDecode(t *testing.T) {
6 dims := []int{3, 2, 4, 17, 26, 15, 2, 1, 2, 1}
8 for i = 0; i < 636480; i++ { // Product of dims
9 addr := DecodeIndex(dims, i)
10 for j := 0; j < len(dims); j++ {
11 if addr[j] >= dims[j] {
15 if EncodeIndex(dims, addr) != i {
21 func TestCommas(t *testing.T) {
22 cases := map[int32]string{
35 for n, s := range cases {