Fix some test failures

This commit is contained in:
Félix Fischer 2019-03-26 13:57:03 -03:00
parent d020565ed2
commit 3cff06a0eb
2 changed files with 5 additions and 6 deletions

View file

@ -161,8 +161,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for Pass {
.ctxt()
.outer()
.expn_info()
.map(|info| info.call_site)
.unwrap_or(expr.span);
.map_or(expr.span, |info| info.call_site);
span_lint_and_then(
cx,
RANGE_PLUS_ONE,

View file

@ -100,13 +100,13 @@ fn run_ui_toml_tests(config: &compiletest::Config, mut tests: Vec<TestDescAndFn>
.position(|test| test.desc.name.to_string() == test_name.to_string())
.expect("The test should be in there");
let opts = libtest::TestOpts {
list: opts.list.clone(),
list: opts.list,
filter: opts.filter.clone(),
filter_exact: opts.filter_exact.clone(),
filter_exact: opts.filter_exact,
exclude_should_panic: Default::default(),
run_ignored: libtest::RunIgnored::No,
run_tests: opts.run_tests.clone(),
bench_benchmarks: opts.bench_benchmarks.clone(),
run_tests: opts.run_tests,
bench_benchmarks: opts.bench_benchmarks,
logfile: opts.logfile.clone(),
nocapture: opts.nocapture,
color: libtest::ColorConfig::AutoColor,