github.com/ncruces/go-sqlite3@v0.15.1-0.20240520133447-53eef1510ff0/driver/util_test.go (about) 1 package driver 2 3 import ( 4 "database/sql/driver" 5 "reflect" 6 "testing" 7 ) 8 9 func Test_namedValues(t *testing.T) { 10 want := []driver.NamedValue{ 11 {Ordinal: 1, Value: true}, 12 {Ordinal: 2, Value: false}, 13 } 14 got := namedValues([]driver.Value{true, false}) 15 if !reflect.DeepEqual(got, want) { 16 t.Errorf("got %v, want %v", got, want) 17 } 18 }