]> git.lizzy.rs Git - rust.git/commitdiff
Add docs for the test crate with the std docs
authorOliver Middleton <olliemail27@gmail.com>
Wed, 28 Mar 2018 21:49:56 +0000 (22:49 +0100)
committerOliver Middleton <olliemail27@gmail.com>
Wed, 28 Mar 2018 21:49:56 +0000 (22:49 +0100)
If the compiler docs aren't going to include the test crate then it may as well be included with std.

src/bootstrap/doc.rs

index 44073a5b0757237bda2fe96abb1aa873e6432756..db79c68bfce5c1fa1e4ed5dfe0444a2e1e26382d 100644 (file)
@@ -512,7 +512,7 @@ impl Step for Test {
 
     fn should_run(run: ShouldRun) -> ShouldRun {
         let builder = run.builder;
-        run.krate("test").default_condition(builder.config.compiler_docs)
+        run.krate("test").default_condition(builder.build.config.docs)
     }
 
     fn make_run(run: RunConfig) {
@@ -555,6 +555,9 @@ fn run(self, builder: &Builder) {
 
         let mut cargo = builder.cargo(compiler, Mode::Libtest, target, "doc");
         compile::test_cargo(build, &compiler, target, &mut cargo);
+
+        cargo.arg("--no-deps").arg("-p").arg("test");
+
         build.run(&mut cargo);
         cp_r(&my_out, &out);
     }