Skip to content

Commit 3df822f

Browse files
committed
Test fixes and review feedback
1 parent 2625276 commit 3df822f

File tree

3 files changed

+16
-18
lines changed

3 files changed

+16
-18
lines changed

src/compiletest/runtest.rs

+15-15
Original file line numberDiff line numberDiff line change
@@ -726,18 +726,18 @@ fn run_debuginfo_lldb_test(config: &Config, props: &TestProps, testfile: &Path)
726726
-> ProcRes {
727727
// Prepare the lldb_batchmode which executes the debugger script
728728
let lldb_script_path = rust_src_root.join("src/etc/lldb_batchmode.py");
729-
cmd2proces(config,
730-
test_executable,
731-
Command::new(&config.python)
732-
.arg(&lldb_script_path)
733-
.arg(test_executable)
734-
.arg(debugger_script)
735-
.env("PYTHONPATH",
736-
config.lldb_python_dir.as_ref().unwrap()))
729+
cmd2procres(config,
730+
test_executable,
731+
Command::new(&config.python)
732+
.arg(&lldb_script_path)
733+
.arg(test_executable)
734+
.arg(debugger_script)
735+
.env("PYTHONPATH",
736+
config.lldb_python_dir.as_ref().unwrap()))
737737
}
738738
}
739739

740-
fn cmd2proces(config: &Config, test_executable: &Path, cmd: &mut Command)
740+
fn cmd2procres(config: &Config, test_executable: &Path, cmd: &mut Command)
741741
-> ProcRes {
742742
let (status, out, err) = match cmd.output() {
743743
Ok(Output { status, stdout, stderr }) => {
@@ -1828,12 +1828,12 @@ fn run_rustdoc_test(config: &Config, props: &TestProps, testfile: &Path) {
18281828
}
18291829
let root = find_rust_src_root(config).unwrap();
18301830

1831-
let res = cmd2proces(config,
1832-
testfile,
1833-
Command::new(&config.python)
1834-
.arg(root.join("src/etc/htmldocck.py"))
1835-
.arg(out_dir)
1836-
.arg(testfile));
1831+
let res = cmd2procres(config,
1832+
testfile,
1833+
Command::new(&config.python)
1834+
.arg(root.join("src/etc/htmldocck.py"))
1835+
.arg(out_dir)
1836+
.arg(testfile));
18371837
if !res.status.success() {
18381838
fatal_proc_rec("htmldocck failed!", &res);
18391839
}

src/librustdoc/test.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ fn scrape_test_config(krate: &::syntax::ast::Crate) -> TestOptions {
124124
use syntax::print::pprust;
125125

126126
let mut opts = TestOptions {
127-
no_crate_inject: true,
127+
no_crate_inject: false,
128128
attrs: Vec::new(),
129129
};
130130

src/test/run-make/issue-22131/foo.rs

-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
#![crate_name="foo"]
12-
1311
/// ```rust
1412
/// assert_eq!(foo::foo(), 1);
1513
/// ```

0 commit comments

Comments
 (0)