]> git.lizzy.rs Git - rust.git/commit
Rollup merge of #48095 - QuietMisdreavus:doctest-assembly, r=GuillaumeGomez
authorGuillaume Gomez <guillaume1.gomez@gmail.com>
Sat, 17 Feb 2018 13:45:20 +0000 (14:45 +0100)
committerGitHub <noreply@github.com>
Sat, 17 Feb 2018 13:45:20 +0000 (14:45 +0100)
commit8aa2852399667b8aa705d2eae066a493bdf54ede
treea9e6cb906f5948739d669a806e0d3605bda2dfbb
parentb85bd51c944f8cbe3a9c4cc95b61e08e5f338052
parent72779936ec89a92731e40e0c406c4620a7c33d7d
Rollup merge of #48095 - QuietMisdreavus:doctest-assembly, r=GuillaumeGomez

add unit tests for rustdoc's processing of doctests

cc #42018

There's a lot of things that rustdoc will do to massage doctests into something that can be compiled, and a lot of options that can be toggled to affect this. Hopefully this list of tests can show off that functionality.

The first commit is slightly unrelated but doesn't touch public functionality, because i found that if you have a manual `fn main`, it adds an extra line break at the end, whereas it would trim this extra line break if it were putting a `fn main` in automatically. That first commit makes it trim out that whitespace ahead of time.