HTTP mocking for Rust!
Get it on crates.io.
Documentation available at https://docs.rs/mockito.
Before upgrading, make sure to check out the changelog.
- Check the existing issues and pull requests.
- One commit is one feature - consider squashing.
- Format code with
cargo fmt. 
Run tests:
cargo test...or run tests using a different toolchain:
rustup run --install 1.36.0 cargo test...or run tests while disabling the default features (e.g. the colors):
cargo test --no-default-featuresMockito uses rustfmt as a general code style.
Install rustfmt:
rustup component add rustfmtFormat code:
cargo fmtSome editors might provide a plugin to format your Rust code automatically.
Mockito uses clippy as a linter.
Install clippy:
rustup component add clippy-previewRun the linter:
# Touch a file to force cargo to rerun clippy on the project
touch src/lib.rs
cargo clippy --lib --tests --all-features -- -D clippy::pedantic -D clippy::nursery...or run the linter using a different toolchain:
rustup run --install 1.36.0 cargo clippy --lib --tests --all-features -- -D clippy::pedantic -D clippy::nurseryRelease:
cargo publishInstall rust nightly:
rustup install nightlyRun benchmarks:
rustup run nightly cargo benchLogo courtesy to http://niastudio.net 👌
