Skip to content

Commit 2256e63

Browse files
authored
Merge pull request #2715 from reddevilmidzy/warn
Add guidance on suppressing warnings in tests
2 parents e245e92 + d61336f commit 2256e63

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/tests/best-practices.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,7 @@ This may include remarks on:
153153
- Try to make sure the test is as minimal as possible.
154154
- Minimize non-critical code and especially minimize unnecessary syntax and type
155155
errors which can clutter stderr snapshots.
156+
- Use `#![allow(...)]` or `#![expect(...)]` to suppress unrelated warnings.
156157
- Where possible, use semantically meaningful names (e.g. `fn
157158
bare_coverage_attributes() {}`).
158159

0 commit comments

Comments
 (0)