Skip to content

Commit

Permalink
Fix missing UINT{32,64,128} data type tests in test-suite (gluesql#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ChobobDev committed Apr 8, 2023
1 parent 0681a1a commit b1953b7
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 3 deletions.
3 changes: 3 additions & 0 deletions test-suite/src/data_type/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ pub mod map;
pub mod sql_types;
pub mod time;
pub mod timestamp;
pub mod uint128;
pub mod uint16;
pub mod uint32;
pub mod uint64;
pub mod uint8;
pub mod uuid;
2 changes: 1 addition & 1 deletion test-suite/src/data_type/uint128.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ test_case!(uint128, async move {
run!(r#"INSERT INTO Item VALUES (1, 1), (2, 2), (3, 3), (4, 4);"#);

test!(
"INSERT INTO Item VALUES (327689,327689);",
"INSERT INTO Item VALUES (340282366920938463463374607431768211456,340282366920938463463374607431768211456);",
Err(ValueError::FailedToParseNumber.into())
);

Expand Down
2 changes: 1 addition & 1 deletion test-suite/src/data_type/uint32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ test_case!(uint32, async move {
run!(r#"INSERT INTO Item VALUES (1, 1), (2, 2), (3, 3), (4, 4);"#);

test!(
"INSERT INTO Item VALUES (327689,327689);",
"INSERT INTO Item VALUES (4294967296,4294967296);",
Err(ValueError::FailedToParseNumber.into())
);

Expand Down
2 changes: 1 addition & 1 deletion test-suite/src/data_type/uint64.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ test_case!(uint64, async move {
run!(r#"INSERT INTO Item VALUES (1, 1), (2, 2), (3, 3), (4, 4);"#);

test!(
"INSERT INTO Item VALUES (327689,327689);",
"INSERT INTO Item VALUES (18446744073709551616,18446744073709551616);",
Err(ValueError::FailedToParseNumber.into())
);

Expand Down
3 changes: 3 additions & 0 deletions test-suite/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,9 @@ macro_rules! generate_store_tests {
glue!(int128, data_type::int128::int128);
glue!(uint16, data_type::uint16::uint16);
glue!(uint8, data_type::uint8::uint8);
glue!(uint64, data_type::uint64::uint64);
glue!(uint32, data_type::uint32::uint32);
glue!(uint128, data_type::uint128::uint128);
glue!(date, data_type::date::date);
glue!(timestamp, data_type::timestamp::timestamp);
glue!(time, data_type::time::time);
Expand Down

0 comments on commit b1953b7

Please sign in to comment.