Skip to content

Commit c320142

Browse files
committed
Fix compile fail test
1 parent 9b33737 commit c320142

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

diesel_compile_tests/tests/compile-fail/pg_specific_expressions_cant_be_used_in_a_sqlite_query.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
use diesel::*;
44
use diesel::sql_types::*;
55
use diesel::dsl::*;
6+
use diesel::upsert::on_constraint;
67

78
table! {
89
users {
@@ -32,6 +33,7 @@ fn main() {
3233
.load::<i32>(&connection);
3334
//~^ ERROR type mismatch resolving `<diesel::SqliteConnection as diesel::Connection>::Backend == diesel::pg::Pg`
3435
insert_into(users).values(&NewUser("Sean"))
35-
.on_conflict(on_constraint("name"));
36-
//~^ ERROR 35:22: 35:35: cannot find function `on_constraint` in this scope [E0425]
36+
.on_conflict(on_constraint("name"))
37+
.execute(&connection);
38+
//~^ ERROR 0599
3739
}

0 commit comments

Comments
 (0)