diff options
| author | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2023-08-08 08:40:31 +0000 |
|---|---|---|
| committer | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2023-08-11 14:03:06 +0000 |
| commit | 43f04e12add4dc15bbbb215467781ee3b2b228b8 (patch) | |
| tree | 07dc36fac0b295c89daa9422c5ffb7ad0971baa2 | |
| parent | 1088507a30e3f1ca263fc653c1b66a50d005e32d (diff) | |
| download | rust-43f04e12add4dc15bbbb215467781ee3b2b228b8.tar.gz rust-43f04e12add4dc15bbbb215467781ee3b2b228b8.zip | |
Bump ui_test crate
| -rw-r--r-- | Cargo.toml | 2 | ||||
| -rw-r--r-- | tests/compile-test.rs | 28 |
2 files changed, 15 insertions, 15 deletions
diff --git a/Cargo.toml b/Cargo.toml index dcdd2161d75..6730888f58a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ tempfile = { version = "3.2", optional = true } termize = "0.1" [dev-dependencies] -ui_test = "0.13" +ui_test = "0.15" tester = "0.9" regex = "1.5" toml = "0.7.3" diff --git a/tests/compile-test.rs b/tests/compile-test.rs index af2e87715b4..fd7839ba7f9 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -201,9 +201,10 @@ fn run_ui() { let quiet = args.quiet; compiletest::run_tests_generic( - config, + vec![config], + std::thread::available_parallelism().unwrap(), args, - move |path, args| compiletest::default_file_filter(path, args) && test_filter(path), + move |path, args, config| compiletest::default_file_filter(path, args, config) && test_filter(path), compiletest::default_per_file_config, if quiet { status_emitter::Text::quiet() @@ -227,9 +228,10 @@ fn run_internal_tests() { let quiet = args.quiet; compiletest::run_tests_generic( - config, + vec![config], + std::thread::available_parallelism().unwrap(), args, - move |path, args| compiletest::default_file_filter(path, args) && test_filter(path), + move |path, args, config| compiletest::default_file_filter(path, args, config) && test_filter(path), compiletest::default_per_file_config, if quiet { status_emitter::Text::quiet() @@ -259,16 +261,15 @@ fn run_ui_toml() { let quiet = args.quiet; ui_test::run_tests_generic( - config, + vec![config], + std::thread::available_parallelism().unwrap(), args, - |path, args| compiletest::default_file_filter(path, args) && test_filter(path), - |config, path| { - let mut config = config.clone(); + |path, args, config| compiletest::default_file_filter(path, args, config) && test_filter(path), + |config, path, _file_contents| { config .program .envs .push(("CLIPPY_CONF_DIR".into(), Some(path.parent().unwrap().into()))); - Some(config) }, if quiet { status_emitter::Text::quiet() @@ -318,11 +319,11 @@ fn run_ui_cargo() { let quiet = args.quiet; ui_test::run_tests_generic( - config, + vec![config], + std::thread::available_parallelism().unwrap(), args, - |path, _args| test_filter(path) && path.ends_with("Cargo.toml"), - |config, path| { - let mut config = config.clone(); + |path, _args, _config| test_filter(path) && path.ends_with("Cargo.toml"), + |config, path, _file_contents| { config.out_dir = canonicalize( std::env::current_dir() .unwrap() @@ -330,7 +331,6 @@ fn run_ui_cargo() { .join("ui_test_cargo/") .join(path.parent().unwrap()), ); - Some(config) }, if quiet { status_emitter::Text::quiet() |
