Skip to content

Commit 3fb8f67

Browse files
committed
api.search: add new test for checking slug_error
1 parent 28f7e19 commit 3fb8f67

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

src/api/search.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,12 @@ mod tests {
2727
assert_eq!(response.title, "Complementary Shaders - Reimagined");
2828
Ok(())
2929
}
30+
31+
#[tokio::test]
32+
async fn asrt_slug_error() -> Result<()> {
33+
let api = ModrinthAPI::default();
34+
let response = api.get_project_by_id("dffdsfdsfsdfdsf").await;
35+
assert!(response.is_err());
36+
Ok(())
37+
}
3038
}

0 commit comments

Comments
 (0)