We welcome contribution from everyone in the form of suggestions, bug reports, pull requests, and feedback. Please note we have a code of conduct, please follow it in all your interactions with the project.
Before uploading any changes, please make sure that the test suite passes locally before submitting a pull request with your changes.
cargo test --all --features run-docker-tests
We also use Clippy to avoid common mistakes and we use rustfmt to make our code clear to everyone.
- Format the code using rustfmt:
cargo fmt
- Make sure there are no warnings and errors. Run the Clippy:
Install cargo udeps
cargo clippy -- -D warnings
cargo install cargo-udeps
- Make sure there are no unused dependencies. Run the following check
Install cargo deny
cargo udeps
cargo install cargo-deny
- Make sure that no new dependencies duplicates appear. Run the following check
cargo deny check bans
- Make sure that dependencies do not have known vulnerabilities. If they do, update them.
cargo deny check advisories
- Install Firefox.
- Download Gecko driver for your OS: https://github.com/mozilla/geckodriver/releases
- Run the tests
WASM_BINDGEN_TEST_TIMEOUT=180 GECKODRIVER=PATH_TO_GECKO_DRIVER_BIN wasm-pack test --firefox --headless mm2src/mm2_main