Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/tests/compiletest.md
Original file line number Diff line number Diff line change
Expand Up @@ -501,10 +501,11 @@ only running the main `coverage` suite.
## Building auxiliary crates

It is common that some tests require additional auxiliary crates to be compiled.
There are two [headers](headers.md) to assist with that:
There are three [headers](headers.md) to assist with that:

* `aux-build`
* `aux-crate`
* `aux-bin`

`aux-build` will build a separate crate from the named source file.
The source file should be in a directory called `auxiliary` beside the test file.
Expand All @@ -529,6 +530,10 @@ For example, `// aux-crate:foo=bar.rs` will compile `auxiliary/bar.rs` and
make it available under then name `foo` within the test.
This is similar to how Cargo does dependency renaming.

`aux-bin` is similar to `aux-build` but will build a binary instead of a
library. The binary will be available in `auxiliary/bin` relative to the working
directory of the test.

### Auxiliary proc-macro

If you want a proc-macro dependency, then there currently is some ceremony
Expand Down