Skip to content

Commit 4dadfd3

Browse files
committed
fix TestQueryTxExecute
1 parent 087d8da commit 4dadfd3

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/integration/query_tx_execute_test.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ func TestQueryTxExecute(t *testing.T) {
3131
)
3232
require.NoError(t, err)
3333
err = db.Query().DoTx(ctx, func(ctx context.Context, tx query.TxActor) (err error) {
34-
res, err := tx.Execute(ctx, "SELECT 1")
34+
res, err := tx.Execute(ctx, "SELECT 1 AS col1")
3535
if err != nil {
3636
return err
3737
}
@@ -43,7 +43,8 @@ func TestQueryTxExecute(t *testing.T) {
4343
if err != nil {
4444
return err
4545
}
46-
err = row.Scan(nil)
46+
var col1 int
47+
err = row.ScanNamed(query.Named("col1", &col1))
4748
if err != nil && !errors.Is(err, internalQuery.ErrNotImplemented) {
4849
return err
4950
}

0 commit comments

Comments
 (0)