Skip to content

Commit 4bd0801

Browse files
IamfromSpaceSh3Rm4n
authored andcommitted
Add documentation on how to run tests to the README.
1 parent 2167e77 commit 4bd0801

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,3 +126,21 @@ expect it to do so.*
126126
## License
127127

128128
[0-clause BSD license](LICENSE-0BSD.txt).
129+
130+
## Contributing
131+
132+
### Running Tests
133+
134+
Tests are run via the integration test pattern and are executed on a target chip, rather than on a host system.
135+
First, install [probe-run](https://crates.io/crates/probe-run) via `cargo install probe-run`.
136+
Next, you'll need to modify `.cargo/config` to link defmt and use `probe-run` configured for your chip.
137+
See details within the comments in that file.
138+
139+
Now, you can execute a test by setting your device, defmt, and any test specific features:
140+
141+
```
142+
cargo test --test rcc --features=stm32f303xc,defmt,rt
143+
```
144+
145+
The result _always_ shows a backtrace, even in the case of success.
146+
Exit code of 0 means that the run was successful.

0 commit comments

Comments
 (0)