Add a warning for unknown default profiles#747
Merged
Conversation
Codecov Report
@@ Coverage Diff @@
## main #747 +/- ##
==========================================
+ Coverage 76.88% 76.90% +0.02%
==========================================
Files 57 57
Lines 12623 12640 +17
==========================================
+ Hits 9705 9721 +16
- Misses 2918 2919 +1
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
27372a3 to
5975d97
Compare
Member
|
Looks good, thank you! |
|
Should #388 be closed? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR addresses #388:
NextestConfigImpl::DEFAULT_PROFILES, a const containing all the nextest defined profiles (at the moment this only includesdefaultanddefault-miri)default-prefix that are not inNextestConfigImpl::DEFAULT_PROFILESand produces a warning for each of themNote that I ended up doing this in
nextest-runner/src/config.rsinstead of incargo-nextestsince AFAICT this is where a lot of the early validation of config files is being done and similar warnings were already being emitted there. Happy to move if you still feel the binary (e.g. somewhere innextest-runner/src/dispatch.rs?) is a better place for this.Test Plan
Ran
cargo xfmtRan
cargo nextest run --all-features. Saw integration-tests failures but they seem unrelated to my changes and they repro on base rev, hopefully CI will tell me if they're legit.Set up a dummy library project with some profiles that should and some that shouldn't trigger this warning.
Then ran the tests with my changes, verified that only the expected profiles trigger the warning
Renamed all profiles to no longer have the
default-prefix, verified that no warnings are triggered