Not to be confused with the rust-analyzer of the Rust project!
rust-analyzer
is a static analysis utility that is used for the automatic mentoring of exercise solutions of Exercism's Rust track.
Please find general documentation about Exercism's language analyzers here.
The utility can be used on the local machine. It accepts two required parameters:
--path
(-p
) - path to the solution directory.--slug
(-s
) - the slug of the exercise that is being analyzed.
For example:
rust-analyzer -p ~/solution-238382y7sds7fsadfasj23j/ -s reverse-string
In the context of the automatic mentoring the utility is invoked inside the Docker container via the bin/analyze.sh
script.
You should have the latest stable version of Rust installed on you machine. Then from the project root run:
cargo build
To run the utility using Cargo execute the following command:
cargo run -- -s exercise_slug -p /path/to/the/solution/directory
To run tests use the following command:
cargo test
Simply run the following script to run the tests in docker:
./bin/run-tests-in-docker.sh