Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compiletest: don't silently accept unsupported directives in test suites #128058

Open
jieyouxu opened this issue Jul 22, 2024 · 1 comment
Open
Labels
A-compiletest Area: The compiletest test runner A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself C-cleanup Category: PRs that clean code up or issues documenting cleanup. E-hard Call for participation: Hard difficulty. Experience needed to fix: A lot. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@jieyouxu
Copy link
Member

Yes, there are special handling here and there for specific directives. But the handling is limited and is only for specific directives in specific test suites.

We should error if a test writer specifies a directive invalid for a given test suite.

This may require reworking how directives are handled, i.e. have test suites "register" what directives they support.

@jieyouxu jieyouxu added C-cleanup Category: PRs that clean code up or issues documenting cleanup. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself A-compiletest Area: The compiletest test runner labels Jul 22, 2024
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Jul 22, 2024
@jieyouxu jieyouxu removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Jul 22, 2024
@jieyouxu jieyouxu changed the title compiletest: don't silently accept unsupported directives for each test suite compiletest: don't silently accept unsupported directives in test suites Jul 22, 2024
@jieyouxu
Copy link
Member Author

jieyouxu commented Oct 17, 2024

This is not maintainable by adding random checks everywhere in the directive handling, it's probably better as a validation pass as part of a rework of directive handling.

@jieyouxu jieyouxu added E-hard Call for participation: Hard difficulty. Experience needed to fix: A lot. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) and removed T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-compiletest Area: The compiletest test runner A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself C-cleanup Category: PRs that clean code up or issues documenting cleanup. E-hard Call for participation: Hard difficulty. Experience needed to fix: A lot. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
Development

No branches or pull requests

2 participants