-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Breakup test.rs
into more-manageable sub-modules
#137224
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
Conversation
…_self_tests` module
…ol_tests` module
…ustdoc_tests` module
…piler_crate_tests` module
… own `dist_tool_tests` module
test.rs
into more-manageable modulestest.rs
into more-manageable sub-modules
I may redo this after #137215. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking at the new files, I think they seem more complicated than before. The policy or motivation behind this splitting logic is unclear.
Example of things that are unclear:
std_tests
can also contain cargo tests, but there is a module called cargotest. Where should we put cargo tests of a program?- Why some tools (like compiletest and rustdoc) have separate module for its tests but not other tools?
- What does cargotest mean? Is it for running cargo tests on projects, or is it for running tests of cargo tool?
- When to create a separate module for tests? What is the right time for it?
- ...the list can go very long.
The separation logic should be very clear and not require us to think too much about when to create a test module or where to place a test.
I'm pretty sure that if we use this structure people will start asking in Zulip threads "Which module should I use to add this test?".
I suggest to keep the module separation as simple and basic as possible.
@rustbot author |
Yeah, I'm not super happy about how this ended up. I'll have to rethink this a bit. |
|
I'll probably revisit this in the future, so closing for the time being. |
Part of Tracking issue for bootstrap test step cleanups #137178.
Summary of changes
Split up
test.rs
into smaller, more logically organized sub-modules.test.rs
file.testdir
to usebuilder.test_out
(to prevent reinventingbuilder.test_out
and having yet another place that might desync in the future).More context
test.rs
into smaller modules by test kind #135072.Review advice
r? @onur-ozkan
Footnotes
For some definition of atomic, I suppose ↩