about summary refs log tree commit diff
path: root/src/tools/tidy
AgeCommit message (Collapse)AuthorLines
2023-01-08Auto merge of #104658 - thomcc:rand-update-and-usable-no_std, r=Mark-Simulacrumbors-1/+0
Update `rand` in the stdlib tests, and remove the `getrandom` feature from it. The main goal is actually removing `getrandom`, so that eventually we can allow running the stdlib test suite on tier3 targets which don't have `getrandom` support. Currently those targets can only run the subset of stdlib tests that exist in uitests, and (generally speaking), we prefer not to test libstd functionality in uitests, which came up recently in https://github.com/rust-lang/rust/pull/104095 and https://github.com/rust-lang/rust/pull/104185. Additionally, the fact that we can't update `rand`/`getrandom` means we're stuck with the old set of tier3 targets, so can't test new ones. ~~Anyway, I haven't checked that this actually does allow use on tier3 targets (I think it does not, as some work is needed in stdlib submodules) but it moves us slightly closer to this, and seems to allow at least finally updating our `rand` dep, which definitely improves the status quo.~~ Checked and works now. For the most part, our tests and benchmarks are fine using hard-coded seeds. A couple tests seem to fail with this (stuff manipulating the environment expecting no collisions, for example), or become pointless (all inputs to a function become equivalent). In these cases I've done a (gross) dance (ab)using `RandomState` and `Location::caller()` for some extra "entropy". Trying to share that code seems *way* more painful than it's worth given that the duplication is a 7-line function, even if the lines are quite gross. (Keeping in mind that sharing it would require adding `rand` as a non-dev dep to std, and exposing a type from it publicly, all of which sounds truly awful, even if done behind a perma-unstable feature). See also some previous attempts: - https://github.com/rust-lang/rust/pull/86963 (in particular https://github.com/rust-lang/rust/pull/86963#issuecomment-885438936 which explains why this is non-trivial) - https://github.com/rust-lang/rust/pull/89131 - https://github.com/rust-lang/rust/pull/96626#issuecomment-1114562857 (I tried in that PR at the same time, but settled for just removing the usage of `thread_rng()` from the benchmarks, since that was the main goal). - https://github.com/rust-lang/rust/pull/104185 - Probably more. It's very tempting of a thing to "just update". r? `@Mark-Simulacrum`
2023-01-07minor fixes for `error_codes.rs` tidy checkEzra Shaw-12/+15
2023-01-06Rollup merge of #106341 - Ezrashaw:refactor-error-code-tidy-check, ↵Matthias Krüger-386/+384
r=mejrs,klensy,GuillaumeGomez refactor: clean up `errors.rs` and `error_codes_check.rs` `errors.rs` is basically unused now, `error_codes_check.rs` is useful but not well commented, etc. It also doesn't check certain things which are certainly not correct. For example, `E0505` has a UI test in `src/test/ui/error-codes/` but that test actually outputs `E0504`?! Other issues like these exist. I've implemented these with "warnings" which are a bit rough around the edges but should be removed eventually. r? `@GuillaumeGomez` (again not sure if you want to review but its relevant to you)
2023-01-04Update rand in the stdlib tests, and remove the getrandom feature from itThom Chiovoloni-1/+0
2023-01-04Rollup merge of #106460 - c410-f3r:moar-errors, r=compiler-errorsMatthias Krüger-1/+1
Move tests r? `@petrochenkov`
2023-01-04tidy: Don't include wasm32 in compiler dependency checkEric Huss-103/+66
2023-01-04Move testsCaio-1/+1
2023-01-04Update cargoWeihang Lo-0/+12
8 commits in 2381cbdb4e9b07090f552d34a44a529b6e620e44..8c460b2237a6359a7e3335890db8da049bdd62fc 2022-12-23 12:19:27 +0000 to 2023-01-04 14:30:01 +0000 - test: revive nightly plugin tests to work (rust-lang/cargo#11534) - Add note to release notes about rejecting multiple registries. (rust-lang/cargo#11531) - Fix a typo `fresheness` -> `freshness` (rust-lang/cargo#11529) - Reasons for rebuilding (rust-lang/cargo#11407) - Asymmetric tokens (rust-lang/cargo#10771) - Use proper git URL for GitHub repos (rust-lang/cargo#11517) - Add `registry.default` example (rust-lang/cargo#11516) - Support vendoring with different revs from same git repo (rust-lang/cargo#10690) Also update license exceptions and permitted dependencies for new cargo dependency "pasetors". A new dependency `getrandom` is added into `rustc-workspace-hacks`, since it requires feature `js`.
2023-01-04Rollup merge of #106327 - gimbles:dbg, r=jyn514Matthias Krüger-0/+17
Add tidy check for dbg Fixes #106169
2023-01-03Rollup merge of #104552 - DebugSteven:warn-newer-x, r=jyn514Matthias Krüger-1/+70
warn newer available version of the x tool This PR adds a check to `tidy` to assert that the installed version of `x` is equal to the version in `src/tools/x/Cargo.toml`. It adds a `--wrapper-version` argument to `x` to determine the version at runtime, . It does not warn if `x` has not yet been installed, on the assumption that the user isn't interested in using it.
2023-01-02no_depsJ Haigh-0/+1
Co-authored-by: Joshua Nelson <github@jyn.dev>
2023-01-02use cargo_metadata to get x versionDebugSteven-28/+11
2023-01-02get latest x version from parsing cargo commandDebugSteven-10/+39
2023-01-03print highest error codeEzra Shaw-0/+1
2023-01-02fix CIEzra Shaw-7/+8
2023-01-02pattern destructure `has_test`Ezra Shaw-3/+1
Co-authored-by: Bruno Kolenbrander <59372212+mejrs@users.noreply.github.com>
2023-01-01Implement fix for #67535Troy Neubauer-1/+1
2023-01-01improve error messageJ Haigh-1/+1
Co-authored-by: Joshua Nelson <github@jyn.dev>
2023-01-01fix typoJ Haigh-1/+1
Co-authored-by: Joshua Nelson <github@jyn.dev>
2023-01-01combine error branchesDebugSteven-3/+1
2023-01-02fixup warningsEzra Shaw-72/+53
2023-01-01fix formattingDebugSteven-4/+8
2023-01-02fix CI errorEzra Shaw-2/+3
2023-01-01handle error case where --wrapper-version argument doesn't existDebugSteven-3/+17
2023-01-02use more paths in error codesEzra Shaw-5/+7
2023-01-02docs: revert removal of `E0729`Ezra Shaw-1/+1
2023-01-01refactor: clean up `errors.rs` and `error_codes_check.rs`Ezra Shaw-386/+400
Move them into new `error_codes.rs` tidy check.
2022-12-31Auto merge of #106336 - matthiaskrgr:rollup-4p6bgwf, r=matthiaskrgrbors-2/+2
Rollup of 4 pull requests Successful merges: - #106280 (docs: add link to `Path::join` in `PathBuf::push`) - #106297 (rustdoc: merge scrape-help CSS) - #106328 (Add comment explaining what the GUI scrape-examples-fonts test is about) - #106334 (Fix tidy unittest.) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-12-31Auto merge of #106282 - Ezrashaw:merge-e0465, r=estebankbors-2/+2
refactor: merge error code `E0465` into `E0464` `E0465` is an undocumented and untested error code that is functionally identical to `E0464`. This PR merges `E0465` into `E0464`, thus documenting and testing another error code (#61137). r? `@GuillaumeGomez` (not sure if you want to review this but it's relevant to my other PRs that you have reviewed)
2022-12-31Fix tidy unittest.Eric Huss-2/+2
2022-12-31rename wrapper-version argument for x to differentiate it from the bootstrap ↵DebugSteven-1/+1
version
2022-12-31Update error messageJ Haigh-1/+1
Co-authored-by: Joshua Nelson <github@jyn.dev>
2022-12-31Update error messageJ Haigh-1/+1
Co-authored-by: Joshua Nelson <github@jyn.dev>
2022-12-31formattingDebugSteven-6/+6
2022-12-31spawn x command and compare semversDebugSteven-10/+30
2022-12-31remove leading comma from macro expansionDebugSteven-23/+5
2022-12-31warn when there's a newer version of the x tool availableDebugSteven-1/+39
2022-12-31Add tidy check for dbggimbles-0/+17
2022-12-31refactor: merge `E0465` into `E0464`Ezra Shaw-2/+2
2022-12-31Revert "Auto merge of #105058 - ↵Joshua Nelson-76/+0
Nilstrieb:no-merge-commits-for-you-only-bors-is-allowed-to-do-that, r=jyn514" This reverts commit 4839886f0abe208ab8f2bb73a3076a59fe2ab60c, reversing changes made to ce85c98575e3016cf2007d90a85be321e592aa96.
2022-12-30Make tidy errors redNilstrieb-9/+23
This makes it easier to see them (and makes people go owo).
2022-12-30Add `build_helper` crate to share code between tidy and bootstrapNilstrieb-59/+4
2022-12-30Tidy up tidy error codes checkNilstrieb-26/+11
2022-12-30Add tidy check to deny merge commitsNilstrieb-0/+131
This will prevent users with the pre-push hook from pushing a merge commit. Exceptions are added for subtree updates. These exceptions are a little hacky and may be non-exhaustive but can be extended in the future.
2022-12-29docs/test: add UI test and long-form error docs for `E0519`Ezra Shaw-2/+2
2022-12-24Rollup merge of #105970 - Ezrashaw:add-docs+test-e0462, r=GuillaumeGomezMatthias Krüger-2/+2
docs/test: add UI test and long-form error docs for E0462 Another UI test/ docs combo. r? ``@GuillaumeGomez``
2022-12-23Move testsCaio-1/+1
2022-12-23docs/test: add UI test and long-form error docs for E0462Ezra Shaw-2/+2
2022-12-20docs/test: add UI test and long-form error docs for `E0377`Ezra Shaw-2/+2
2022-12-17poll tidy threads for completion before waitingThe 8472-6/+16