A workspace containing multiple small Rust demonstration projects with comprehensive testing and modern tooling.
- 01_hello_world: Simple hello world with unit tests, integration tests, and doctests
- 02_add_two_numbers: Interactive calculator with input validation and comprehensive testing
- 03_axum_hello_world: Modern async web server with HTTP endpoint testing
- 🦀 Modern Rust with 2021 edition
- 🏗️ Workspace-based dependency management
- 🧪 Comprehensive testing (unit, integration, doctests)
- 📊 Code coverage reporting with tarpaulin
- 🌐 Real HTTP integration testing with reqwest
- 🎯 Lint configuration for code quality
- 🔧 Unified spawn functions for easy testing
# Build all projects
cargo build --workspace
# Run all tests
cargo test --workspace
# Generate coverage report
cargo tarpaulin --workspace --out Html
# Run individual projects
cargo run -p hello_world
cargo run -p add_two_numbers
cargo run -p axum_hello_world
Each project includes multiple test types:
- Unit tests in
src/
files - Integration tests in
tests/
directories - Documentation tests in rustdoc comments
The Axum project features real HTTP integration testing by spawning the server and making actual requests.
All dependencies are managed at the workspace level for consistency. The workspace uses resolver v2 for optimal dependency unification.