-
-
Notifications
You must be signed in to change notification settings - Fork 15k
compiletest: Deficiencies and pitfalls of //@ normalize-* headers #126372
Copy link
Copy link
Open
Labels
A-compiletestArea: The compiletest test runnerArea: The compiletest test runnerA-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustcC-bugCategory: This is a bug.Category: This is a bug.E-mediumCall for participation: Medium difficulty. Experience needed to fix: Intermediate.Call for participation: Medium difficulty. Experience needed to fix: Intermediate.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Metadata
Metadata
Assignees
Labels
A-compiletestArea: The compiletest test runnerArea: The compiletest test runnerA-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustcC-bugCategory: This is a bug.Category: This is a bug.E-mediumCall for participation: Medium difficulty. Experience needed to fix: Intermediate.Call for participation: Medium difficulty. Experience needed to fix: Intermediate.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Type
Fields
Give feedbackNo fields configured for issues without a type.
These headers allow individual tests to define custom output-normalization rules, so that output snapshots are less sensitive to things like platform differences, line numbers, and timestamps.
Unfortunately, they have a few limitations and pitfalls:
//@ normalize-*headers #126370:after the header name, so the test suite contains an inconsistent mix of with-colon and without-colon rules.//@ normalize-*:test headers #126777"characters, which is very awkward for some kinds of output (e.g. JSON).parse_cfg_name_directiveto help read the header name, which is sometimes useful (e.g. for defining separate rules for 32-bit and 64-bit), but most of the time it means that tests have to awkwardly writenormalize-stderr-testinstead of the more intuitivenormalize-stderr.ui-mode tests, and are silently ignored if they appear in other kinds of test.@rustbot label +A-compiletest