diff options
| author | Michael Goulet <michael@errs.io> | 2024-05-03 23:34:24 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-03 23:34:24 -0400 |
| commit | 683197701cd926e7f3c7077abc7411ae1c462677 (patch) | |
| tree | 3518eb16653696e6fc5fcb6de5fa4e394bbad220 /library/test | |
| parent | 93ca906cb572d8754dc43773a3cd502717fd8f07 (diff) | |
| parent | dde17cf3ee25d3212aae47907ef5e9edc056cd5b (diff) | |
| download | rust-683197701cd926e7f3c7077abc7411ae1c462677.tar.gz rust-683197701cd926e7f3c7077abc7411ae1c462677.zip | |
Rollup merge of #124681 - risc0:erik/fix-test, r=joboet
zkvm: fix run_tests `zkvm` is single-threaded, similar to `emscripten` and `wasm`. The `cfg` for `zkvm` seems to have been dropped. This PR adds the `cfg` again.
Diffstat (limited to 'library/test')
| -rw-r--r-- | library/test/src/lib.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/library/test/src/lib.rs b/library/test/src/lib.rs index f3a26e25938..7bd08a0605f 100644 --- a/library/test/src/lib.rs +++ b/library/test/src/lib.rs @@ -589,7 +589,9 @@ pub fn run_test( // If the platform is single-threaded we're just going to run // the test synchronously, regardless of the concurrency // level. - let supports_threads = !cfg!(target_os = "emscripten") && !cfg!(target_family = "wasm"); + let supports_threads = !cfg!(target_os = "emscripten") + && !cfg!(target_family = "wasm") + && !cfg!(target_os = "zkvm"); if supports_threads { let cfg = thread::Builder::new().name(name.as_slice().to_owned()); let mut runtest = Arc::new(Mutex::new(Some(runtest))); |
