Skip to content

Commit

Permalink
Expand test to include NULL case
Browse files Browse the repository at this point in the history
  • Loading branch information
KyGost committed Mar 24, 2021
1 parent c920e97 commit 0b17e05
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/tests/column_options/auto_increment.rs
Expand Up @@ -31,6 +31,19 @@ test_case!(auto_increment, async move {
1 "test1".to_owned();
2 "test2".to_owned()),
),
(
r#"INSERT INTO Test (name, id) VALUES ('test3', NULL)"#,
Payload::Insert(1),
), // Debatable behavior. I (KG) think this is acceptable and correct.
(
r#"SELECT * FROM Test"#,
select!(
id | name
I64 | Str;
1 "test1".to_owned();
2 "test2".to_owned();
3 "test3".to_owned()),
),
];

for (sql, expected) in test_cases.into_iter() {
Expand Down

0 comments on commit 0b17e05

Please sign in to comment.