-
Notifications
You must be signed in to change notification settings - Fork 501
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
Automatically check if README.md examples are working when running "cargo test" #657
Conversation
How do I know if this worked? I don't see README tests in the log: |
It only work on nightly for the moment. The PR got merged recently: rust-lang/rust#59940, so in 6 weeks it'll be in beta and then on stable (but you already know how it works I assume ;) ). I can add tests for nightly on your CI if you want alongside the others? |
Ah, we do have CI for nightly, but only on the full bors check. Let's just go for it: bors r+ |
657: Automatically check if README.md examples are working when running "cargo test" r=cuviper a=GuillaumeGomez Since rustdoc nightly now provides "cfg(test)" when running on test mode, we can now use this macro on test mode only to check if README.md examples are working as expected. Co-authored-by: Guillaume Gomez <[email protected]>
Build failed |
Can you tell me what failed please? :) |
Looks like a UI issue in rayon-core, unrelated to your change:
|
Oh? That's surprising. Well, I'll let you handle this part then. Thanks for showing me the error! :) |
I believe the error change is from NLL being enabled for 2015 edition. Fortunately, bors r+ |
657: Automatically check if README.md examples are working when running "cargo test" r=cuviper a=GuillaumeGomez Since rustdoc nightly now provides "cfg(test)" when running on test mode, we can now use this macro on test mode only to check if README.md examples are working as expected. Co-authored-by: Guillaume Gomez <[email protected]> Co-authored-by: Josh Stone <[email protected]>
Build failed |
Bah, more error changes in rayon-futures... |
bors r+ |
657: Automatically check if README.md examples are working when running "cargo test" r=cuviper a=GuillaumeGomez Since rustdoc nightly now provides "cfg(test)" when running on test mode, we can now use this macro on test mode only to check if README.md examples are working as expected. Co-authored-by: Guillaume Gomez <[email protected]> Co-authored-by: Josh Stone <[email protected]>
Congrats and thanks for fixing! |
Since rustdoc nightly now provides "cfg(test)" when running on test mode, we can now use this macro on test mode only to check if README.md examples are working as expected.