mirror of
https://github.com/launchbadge/sqlx.git
synced 2025-12-29 21:00:54 +00:00
postgres: be explicit about an expression type for a test
This commit is contained in:
parent
40e1df78f1
commit
63f5592ecf
@ -119,6 +119,6 @@ macro_rules! Sqlite_query_for_test_prepared_type {
|
||||
#[macro_export]
|
||||
macro_rules! Postgres_query_for_test_prepared_type {
|
||||
() => {
|
||||
"SELECT {0} is not distinct from $1, $2::text as _1, {0}, $3 as _3"
|
||||
"SELECT {0} is not distinct from $1, $2::text as _1, {0} as _2, $3 as _3"
|
||||
};
|
||||
}
|
||||
|
||||
@ -141,7 +141,7 @@ mod chrono {
|
||||
test_type!(chrono_date_time(
|
||||
Postgres,
|
||||
NaiveDateTime,
|
||||
"'2019-01-02 05:10:20'" == NaiveDate::from_ymd(2019, 1, 2).and_hms(5, 10, 20)
|
||||
"'2019-01-02 05:10:20'::timestamp" == NaiveDate::from_ymd(2019, 1, 2).and_hms(5, 10, 20)
|
||||
));
|
||||
|
||||
test_type!(chrono_date_time_tz(
|
||||
@ -256,7 +256,7 @@ DO $$ BEGIN
|
||||
CREATE TYPE _sqlx_record_1 AS (_1 int8);
|
||||
EXCEPTION
|
||||
WHEN duplicate_object THEN null;
|
||||
END $$;
|
||||
END $$;
|
||||
"#,
|
||||
)
|
||||
.await?;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user