Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 00b382d

Browse files
committed
add num_cpus crate test
1 parent 963f08b commit 00b382d

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed

test_dependencies/Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test_dependencies/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ edition = "2021"
1212
tokio = { version = "1.0", features = ["full"] }
1313
libc = "0.2"
1414
page_size = "0.4.1"
15+
num_cpus = "1.10.1"
1516

1617
getrandom_1 = { package = "getrandom", version = "0.1" }
1718
getrandom_2 = { package = "getrandom", version = "0.2" }

tests/pass/crates/num_cpus.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
//@compile-flags: -Zmiri-disable-isolation
2+
3+
fn main() {
4+
assert_eq!(num_cpus::get(), 1);
5+
}

tests/pass/crates/random.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
use rand::{rngs::SmallRng, Rng, SeedableRng};
21
// mac-os `getrandom_1` does some pointer shenanigans
32
//@compile-flags: -Zmiri-permissive-provenance
3+
use rand::{rngs::SmallRng, Rng, SeedableRng};
44

55
fn main() {
66
// Test `getrandom` directly (in multiple different versions).

0 commit comments

Comments
 (0)