use install;
use dist;
use util::{exe, libdir, add_lib_path};
-use {Build, Mode, DocTestsOption};
+use {Build, Mode, DocTests};
use cache::{INTERNER, Interned, Cache};
use check;
use test;
format!("{} {}", env::var("RUSTFLAGS").unwrap_or_default(), extra_args));
}
- let want_rustdoc = self.doc_tests != DocTestsOption::No;
+ let want_rustdoc = self.doc_tests != DocTests::No;
// Customize the compiler we're running. Specify the compiler to cargo
// as our shim and then pass it some various options used to configure
test_args: vec![],
rustc_args: vec![],
fail_fast: true,
- doc_tests: DocTestsOption::No,
+ doc_tests: DocTests::No,
};
let build = Build::new(config);
use getopts::Options;
-use {Build, DocTestsOption};
+use {Build, DocTests};
use config::Config;
use metadata;
use builder::Builder;
test_args: Vec<String>,
rustc_args: Vec<String>,
fail_fast: bool,
- doc_tests: DocTestsOption,
+ doc_tests: DocTests,
},
Bench {
paths: Vec<PathBuf>,
rustc_args: matches.opt_strs("rustc-args"),
fail_fast: !matches.opt_present("no-fail-fast"),
doc_tests: if matches.opt_present("doc") {
- DocTestsOption::Only
+ DocTests::Only
} else if matches.opt_present("no-doc") {
- DocTestsOption::No
+ DocTests::No
} else {
- DocTestsOption::Yes
+ DocTests::Yes
}
}
}
}
}
- pub fn doc_tests(&self) -> DocTestsOption {
+ pub fn doc_tests(&self) -> DocTests {
match *self {
Subcommand::Test { doc_tests, .. } => doc_tests,
- _ => DocTestsOption::Yes,
+ _ => DocTests::Yes,
}
}
}
}
#[derive(PartialEq, Eq, Copy, Clone, Debug)]
-pub enum DocTestsOption {
+pub enum DocTests {
// Default, run normal tests and doc tests.
Yes,
// Do not run any doc tests.
rustfmt_info: channel::GitInfo,
local_rebuild: bool,
fail_fast: bool,
- doc_tests: DocTestsOption,
+ doc_tests: DocTests,
verbosity: usize,
// Targets for which to build.
use native;
use tool::{self, Tool};
use util::{self, dylib_path, dylib_path_var};
-use {Mode, DocTestsOption};
+use {Mode, DocTests};
use toolstate::ToolState;
const ADB_TEST_DIR: &str = "/data/tmp/work";
cargo.arg("--no-fail-fast");
}
match builder.doc_tests {
- DocTestsOption::Only => {
+ DocTests::Only => {
cargo.arg("--doc");
}
- DocTestsOption::No => {
+ DocTests::No => {
cargo.args(&["--lib", "--bins", "--examples", "--tests", "--benches"]);
}
- DocTestsOption::Yes => {}
+ DocTests::Yes => {}
}
cargo.arg("-p").arg(krate);