mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-10-28 06:36:18 +00:00
chore: replace result assertions (#1840)
* s/assert!\((.*)\.is_ok\(\)\);/\1.unwrap\(\);/g * s/assert!\((.*)\.is_some\(\)\);/\1.unwrap\(\);/g
This commit is contained in:
@@ -122,7 +122,10 @@ pub async fn test_mysql_crud(store_type: StorageType) {
|
||||
assert_eq!(ret, 6);
|
||||
}
|
||||
|
||||
assert!(sqlx::query("delete from demo").execute(&pool).await.is_ok());
|
||||
let _ = sqlx::query("delete from demo")
|
||||
.execute(&pool)
|
||||
.await
|
||||
.unwrap();
|
||||
let rows = sqlx::query("select i from demo")
|
||||
.fetch_all(&pool)
|
||||
.await
|
||||
@@ -180,7 +183,10 @@ pub async fn test_postgres_crud(store_type: StorageType) {
|
||||
assert_eq!(ret, 6);
|
||||
}
|
||||
|
||||
assert!(sqlx::query("delete from demo").execute(&pool).await.is_ok());
|
||||
let _ = sqlx::query("delete from demo")
|
||||
.execute(&pool)
|
||||
.await
|
||||
.unwrap();
|
||||
let rows = sqlx::query("select i from demo")
|
||||
.fetch_all(&pool)
|
||||
.await
|
||||
|
||||
Reference in New Issue
Block a user