This site is being rebuilt and some pages are out of date. For current details, write to [email protected]. This notice goes away when the rebuild is done.

No analytics unless you allow it, no tracking. This site keeps in your browser the language you pick, the theme, its colour, which site you chose, the currency on the pricing page and that you closed this notice; signing in adds session cookies. The legal page has the details.

Sign in

Radar · Rust · Archive · Week 15 · Apr 7 – 13, 2025

This Month in Our Test Infra: March 2025 issue

Nice to knowtooling

What changed
The Rust team reported on the status of the test infrastructure for March 2025.
Production impact
The source does not say.
Try it
Run cargo test --verbose to see your own test output.
Source
blog.rust-lang.org/inside-rust/2025/04/13/test-infra-mar-2025/

Understand it, then run it

The Rust test system, called compiletest, now lets you match compiler diagnostics that appear after a line of code. Previously you could only match diagnostics that happened on the same line or earlier. This is useful when a test file contains code that is not valid Rust, so you cannot put a comment after the line to match the error. compiletest also added a new way to match diagnostics that don’t have a line number. Instead of using the older //@ error-pattern, you can write //~? ERROR message at the end of the file. This tells the test runner to look for an error with that exact message, even if the compiler didn’t attach a line number to it. If you run tests that use the old //@ error-pattern, the new system will now require you to add a //~ annotation anyway, so you don’t accidentally ignore errors. Finally, the bootstrap tool that builds Rust now uses a file called bootstrap.toml instead of config.toml. This avoids confusion with Cargo’s own configuration file.

Written by gpt-oss-20b from the linked source · claims checked against the sources · archive, not individually reviewed