Skip to content

Commit 61199fe

Browse files
committed
Remove fully qualified import for asset_eq
1 parent 903b248 commit 61199fe

File tree

2 files changed

+17
-17
lines changed

2 files changed

+17
-17
lines changed

tests/sqlparser_common.rs

+7-7
Original file line numberDiff line numberDiff line change
@@ -4066,8 +4066,8 @@ fn test_alter_table_with_on_cluster() {
40664066
Statement::AlterTable {
40674067
name, on_cluster, ..
40684068
} => {
4069-
std::assert_eq!(name.to_string(), "t");
4070-
std::assert_eq!(on_cluster, Some(Ident::with_quote('\'', "cluster")));
4069+
assert_eq!(name.to_string(), "t");
4070+
assert_eq!(on_cluster, Some(Ident::with_quote('\'', "cluster")));
40714071
}
40724072
_ => unreachable!(),
40734073
}
@@ -4078,15 +4078,15 @@ fn test_alter_table_with_on_cluster() {
40784078
Statement::AlterTable {
40794079
name, on_cluster, ..
40804080
} => {
4081-
std::assert_eq!(name.to_string(), "t");
4082-
std::assert_eq!(on_cluster, Some(Ident::new("cluster_name")));
4081+
assert_eq!(name.to_string(), "t");
4082+
assert_eq!(on_cluster, Some(Ident::new("cluster_name")));
40834083
}
40844084
_ => unreachable!(),
40854085
}
40864086

40874087
let res = all_dialects()
40884088
.parse_sql_statements("ALTER TABLE t ON CLUSTER 123 ADD CONSTRAINT bar PRIMARY KEY (baz)");
4089-
std::assert_eq!(
4089+
assert_eq!(
40904090
res.unwrap_err(),
40914091
ParserError::ParserError("Expected: identifier, found: 123".to_string())
40924092
)
@@ -11226,7 +11226,7 @@ fn test_group_by_nothing() {
1122611226
let Select { group_by, .. } = all_dialects_where(|d| d.supports_group_by_expr())
1122711227
.verified_only_select("SELECT count(1) FROM t GROUP BY ()");
1122811228
{
11229-
std::assert_eq!(
11229+
assert_eq!(
1123011230
GroupByExpr::Expressions(vec![Expr::Tuple(vec![])], vec![]),
1123111231
group_by
1123211232
);
@@ -11235,7 +11235,7 @@ fn test_group_by_nothing() {
1123511235
let Select { group_by, .. } = all_dialects_where(|d| d.supports_group_by_expr())
1123611236
.verified_only_select("SELECT name, count(1) FROM t GROUP BY name, ()");
1123711237
{
11238-
std::assert_eq!(
11238+
assert_eq!(
1123911239
GroupByExpr::Expressions(
1124011240
vec![
1124111241
Identifier(Ident::new("name".to_string())),

tests/sqlparser_snowflake.rs

+10-10
Original file line numberDiff line numberDiff line change
@@ -2649,15 +2649,15 @@ fn parse_use() {
26492649
let quote_styles = ['\'', '"', '`'];
26502650
for object_name in &valid_object_names {
26512651
// Test single identifier without quotes
2652-
std::assert_eq!(
2652+
assert_eq!(
26532653
snowflake().verified_stmt(&format!("USE {}", object_name)),
26542654
Statement::Use(Use::Object(ObjectName(vec![Ident::new(
26552655
object_name.to_string()
26562656
)])))
26572657
);
26582658
for &quote in &quote_styles {
26592659
// Test single identifier with different type of quotes
2660-
std::assert_eq!(
2660+
assert_eq!(
26612661
snowflake().verified_stmt(&format!("USE {}{}{}", quote, object_name, quote)),
26622662
Statement::Use(Use::Object(ObjectName(vec![Ident::with_quote(
26632663
quote,
@@ -2669,7 +2669,7 @@ fn parse_use() {
26692669

26702670
for &quote in &quote_styles {
26712671
// Test double identifier with different type of quotes
2672-
std::assert_eq!(
2672+
assert_eq!(
26732673
snowflake().verified_stmt(&format!("USE {0}CATALOG{0}.{0}my_schema{0}", quote)),
26742674
Statement::Use(Use::Object(ObjectName(vec![
26752675
Ident::with_quote(quote, "CATALOG"),
@@ -2678,7 +2678,7 @@ fn parse_use() {
26782678
);
26792679
}
26802680
// Test double identifier without quotes
2681-
std::assert_eq!(
2681+
assert_eq!(
26822682
snowflake().verified_stmt("USE mydb.my_schema"),
26832683
Statement::Use(Use::Object(ObjectName(vec![
26842684
Ident::new("mydb"),
@@ -2688,35 +2688,35 @@ fn parse_use() {
26882688

26892689
for &quote in &quote_styles {
26902690
// Test single and double identifier with keyword and different type of quotes
2691-
std::assert_eq!(
2691+
assert_eq!(
26922692
snowflake().verified_stmt(&format!("USE DATABASE {0}my_database{0}", quote)),
26932693
Statement::Use(Use::Database(ObjectName(vec![Ident::with_quote(
26942694
quote,
26952695
"my_database".to_string(),
26962696
)])))
26972697
);
2698-
std::assert_eq!(
2698+
assert_eq!(
26992699
snowflake().verified_stmt(&format!("USE SCHEMA {0}my_schema{0}", quote)),
27002700
Statement::Use(Use::Schema(ObjectName(vec![Ident::with_quote(
27012701
quote,
27022702
"my_schema".to_string(),
27032703
)])))
27042704
);
2705-
std::assert_eq!(
2705+
assert_eq!(
27062706
snowflake().verified_stmt(&format!("USE SCHEMA {0}CATALOG{0}.{0}my_schema{0}", quote)),
27072707
Statement::Use(Use::Schema(ObjectName(vec![
27082708
Ident::with_quote(quote, "CATALOG"),
27092709
Ident::with_quote(quote, "my_schema")
27102710
])))
27112711
);
2712-
std::assert_eq!(
2712+
assert_eq!(
27132713
snowflake().verified_stmt(&format!("USE ROLE {0}my_role{0}", quote)),
27142714
Statement::Use(Use::Role(ObjectName(vec![Ident::with_quote(
27152715
quote,
27162716
"my_role".to_string(),
27172717
)])))
27182718
);
2719-
std::assert_eq!(
2719+
assert_eq!(
27202720
snowflake().verified_stmt(&format!("USE WAREHOUSE {0}my_wh{0}", quote)),
27212721
Statement::Use(Use::Warehouse(ObjectName(vec![Ident::with_quote(
27222722
quote,
@@ -2728,7 +2728,7 @@ fn parse_use() {
27282728
// Test invalid syntax - missing identifier
27292729
let invalid_cases = ["USE SCHEMA", "USE DATABASE", "USE WAREHOUSE"];
27302730
for sql in &invalid_cases {
2731-
std::assert_eq!(
2731+
assert_eq!(
27322732
snowflake().parse_sql_statements(sql).unwrap_err(),
27332733
ParserError::ParserError("Expected: identifier, found: EOF".to_string()),
27342734
);

0 commit comments

Comments
 (0)