Skip to content

Commit 95ce237

Browse files
lqdtshepang
authored andcommitted
document .x test --rustc-args option
1 parent e592090 commit 95ce237

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Diff for: src/tests/running.md

+9
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,15 @@ Under the hood, the test runner invokes the standard Rust test runner
133133
filtering for tests that include "issue-1234" in the name. (Thus
134134
`--test-args` is a good way to run a collection of related tests.)
135135

136+
## Passing arguments to `rustc` when running tests
137+
138+
It can sometimes be useful to run some tests with specific compiler arguments,
139+
without using `RUSTFLAGS` (during development of unstable features, with `-Z`
140+
flags, for example).
141+
142+
This can be done with `./x test`'s `--rustc-args` option, to pass additional
143+
arguments to the compiler when building the tests.
144+
136145
## Editing and updating the reference files
137146

138147
If you have changed the compiler's output intentionally, or you are

0 commit comments

Comments
 (0)