-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-doctestsArea: Documentation tests, run by rustdocArea: Documentation tests, run by rustdocC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.I-compiletimeIssue: Problems and improvements with respect to compile times.Issue: Problems and improvements with respect to compile times.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.
Description
Raised by @Lokathor on discord:
Doctests are slower to run than integration tests. Each individual doctest block runs as a unique binary/process when testing, but each entire integration test file runs as a single process with integration tests. So the test themselves aren't different speeds, but because you're building less bins and spawning less child processes it's faster to go through the integration tests.
I don't think there's any intrinsic reason the tests have to be their own process? The only issue is that many of them have fn main
, which would have to be rewritten somehow. This could speed up CI times across the Rust ecosystem, including for the rust compiler itself.
Somewhat related to #51228.
jorgecarleitao, mina86, untitaker, manuel-woelker, Iron-E and 14 more
Metadata
Metadata
Assignees
Labels
A-doctestsArea: Documentation tests, run by rustdocArea: Documentation tests, run by rustdocC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.I-compiletimeIssue: Problems and improvements with respect to compile times.Issue: Problems and improvements with respect to compile times.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.
Type
Projects
Status
Done