Sha256: 3ba63e4ba945826d67799e3650b542fbf1be128530a7ea76904d86fba448b978

Contents?: true

Size: 572 Bytes

Versions: 16

Compression:

Stored size: 572 Bytes

Contents

mod common;

#[test]
fn test_random() {
    let (store, instance) = common::create_instance("random.wasm");
    let result = common::invoke_func::<(), i32>(store, instance, "random", ());
    let expected_random_output = 155;
    assert_eq!(result, expected_random_output);
}

#[test]
fn test_random_two_invocations() {
    let (store, instance) = common::create_instance("random.wasm");
    let result = common::invoke_func::<(), i32>(store, instance, "random_two_invocations", ());
    let expected_random_output = 111;
    assert_eq!(result, expected_random_output);
}

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
wasmtime-29.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.29/tests/random.rs
wasmtime-28.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.28/tests/random.rs
wasmtime-27.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.27/tests/random.rs
wasmtime-26.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.26/tests/random.rs
wasmtime-25.0.2 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.25/tests/random.rs
wasmtime-25.0.1 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.25/tests/random.rs
wasmtime-25.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.25/tests/random.rs
wasmtime-24.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.24/tests/random.rs
wasmtime-23.0.2 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.23/tests/random.rs
wasmtime-22.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.22/tests/random.rs
wasmtime-21.0.1 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.22/tests/random.rs
wasmtime-20.0.2 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.21/tests/random.rs
wasmtime-20.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.21/tests/random.rs
wasmtime-18.0.3 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.19/tests/random.rs
wasmtime-17.0.1 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.18/tests/random.rs
wasmtime-17.0.0 ./ext/cargo-vendor/deterministic-wasi-ctx-0.1.18/tests/random.rs