Sha256: 8c208ce45e83ab1dfc5890353d5b2f06fc8005684ae622827a65d05abb35a072

Contents?: true

Size: 474 Bytes

Versions: 33

Compression:

Stored size: 474 Bytes

Contents

use rayon_core::ThreadPoolBuilder;
use std::error::Error;

#[test]
#[cfg_attr(any(target_os = "emscripten", target_family = "wasm"), ignore)]
fn double_init_fail() {
    let result1 = ThreadPoolBuilder::new().build_global();
    assert!(result1.is_ok());
    let err = ThreadPoolBuilder::new().build_global().unwrap_err();
    assert!(err.source().is_none());
    assert_eq!(
        err.to_string(),
        "The global thread pool has already been initialized.",
    );
}

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
wasmtime-29.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-28.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-27.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-26.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-25.0.2 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-25.0.1 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-25.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-24.0.0 ./ext/cargo-vendor/rayon-core-1.12.1/tests/double_init_fail.rs
wasmtime-23.0.2 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-22.0.0 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-21.0.1 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-20.0.2 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-20.0.0 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-18.0.3 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-17.0.1 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-17.0.0 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-16.0.0 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-15.0.1 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-15.0.0 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs
wasmtime-14.0.4 ./ext/cargo-vendor/rayon-core-1.12.0/tests/double_init_fail.rs