mirror of
https://github.com/jackc/pgx.git
synced 2025-04-28 05:37:41 +00:00
Tweak test for PG 12 compatibility
This commit is contained in:
parent
2f2e01b9fc
commit
eb360b07be
@ -13,12 +13,12 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/cockroachdb/apd"
|
"github.com/cockroachdb/apd"
|
||||||
|
"github.com/gofrs/uuid"
|
||||||
"github.com/jackc/pgconn"
|
"github.com/jackc/pgconn"
|
||||||
"github.com/jackc/pgconn/stmtcache"
|
"github.com/jackc/pgconn/stmtcache"
|
||||||
"github.com/jackc/pgtype"
|
"github.com/jackc/pgtype"
|
||||||
gofrs "github.com/jackc/pgtype/ext/gofrs-uuid"
|
gofrs "github.com/jackc/pgtype/ext/gofrs-uuid"
|
||||||
"github.com/jackc/pgx/v4"
|
"github.com/jackc/pgx/v4"
|
||||||
"github.com/gofrs/uuid"
|
|
||||||
"github.com/shopspring/decimal"
|
"github.com/shopspring/decimal"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
@ -582,7 +582,7 @@ func TestQueryEncodeError(t *testing.T) {
|
|||||||
if rows.Err() == nil {
|
if rows.Err() == nil {
|
||||||
t.Error("Expected rows.Err() to return error, but it didn't")
|
t.Error("Expected rows.Err() to return error, but it didn't")
|
||||||
}
|
}
|
||||||
if rows.Err().Error() != `ERROR: invalid input syntax for integer: "wrong" (SQLSTATE 22P02)` {
|
if !strings.Contains(rows.Err().Error(), "SQLSTATE 22P02") {
|
||||||
t.Error("Expected rows.Err() to return different error:", rows.Err())
|
t.Error("Expected rows.Err() to return different error:", rows.Err())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user