Helpful Resources

This article lists some helpful resources on Rust. Blogs Rust Blog by Pretzelhammer Articles Stack Overflow AsRef<T> in Rust Answered by PretzelHammer.

September 28, 2025 · 1 min

Rust Testing

Reproducible testing is important for reliable software development. Rust has a powerful built-in testing features, so that test can be writting under the test modules, and invoked by cargo test. For more details, see rust doc. This blogs will focus on some convenient use cases. How to Write Tests. fn plus_one(x: i32) -> i32 { x + 1 } fn main() { } #[cfg(test)] mod tests{ #[test] fn it_works() { assert_eq!(2, super::plus_one(1)); } } And fire the test with cargo test. ...

September 10, 2025 · 1 min · 174 words

Error Handling in Rust

Error Handling in Rust Color Eyre This package is simply magical.

May 4, 2025 · 1 min · 11 words