about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEric Huss <eric@huss.org>2020-06-11 18:28:13 -0700
committerEric Huss <eric@huss.org>2020-06-11 18:28:13 -0700
commit57b54c49281df9559cae4a685c0d38d62a3ee500 (patch)
tree428b27d4f6dfe8bf83fc08cccee7d88114fedea4
parenta37c32e2d5fb186627ffe99a391c7fd6fd159334 (diff)
downloadrust-57b54c49281df9559cae4a685c0d38d62a3ee500.tar.gz
rust-57b54c49281df9559cae4a685c0d38d62a3ee500.zip
Use the built cargo for cargotest.
-rw-r--r--src/bootstrap/test.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
index 163132f5634..aeabb227cf5 100644
--- a/src/bootstrap/test.rs
+++ b/src/bootstrap/test.rs
@@ -154,6 +154,7 @@ impl Step for Cargotest {
     fn run(self, builder: &Builder<'_>) {
         let compiler = builder.compiler(self.stage, self.host);
         builder.ensure(compile::Rustc { compiler, target: compiler.host });
+        let cargo = builder.ensure(tool::Cargo { compiler, target: compiler.host });
 
         // Note that this is a short, cryptic, and not scoped directory name. This
         // is currently to minimize the length of path on Windows where we otherwise
@@ -165,7 +166,7 @@ impl Step for Cargotest {
         let mut cmd = builder.tool_cmd(Tool::CargoTest);
         try_run(
             builder,
-            cmd.arg(&builder.initial_cargo)
+            cmd.arg(&cargo)
                 .arg(&out_dir)
                 .env("RUSTC", builder.rustc(compiler))
                 .env("RUSTDOC", builder.rustdoc(compiler)),