Expand description
Test utilities for downstream users.
Feature-gated — enable with features = ["test-utils"].
Provides deterministic seeds, keys, nonces, and byte generators so users can write tests against the SDK without hitting real randomness.
§Example
ⓘ
use origin_crypto_sdk::test_utils::deterministic_seed;
let seed = deterministic_seed(42);Test utilities for downstream users.
This module provides deterministic seeds, mock key generation, and proptest strategies so users can write tests against the SDK without touching real cryptographic randomness.
Feature-gated — only available with features = ["test-utils"].
§Example
ⓘ
use origin_crypto_sdk::test_utils::deterministic_seed;
let seed = deterministic_seed(42);
// Use seed for key derivation, signing, etc.Functions§
- deterministic_
bytes - Generate a deterministic random-ish byte vector of the given length.
- deterministic_
ed25519_ key - Generate a deterministic Ed25519 signing key for testing.
- deterministic_
key - Generate a deterministic 32-byte key for testing AEAD operations.
- deterministic_
nonce_ 12 - Generate a deterministic 12-byte nonce for testing.
- deterministic_
nonce_ 24 - Generate a deterministic 24-byte nonce for testing.
- deterministic_
seed - A deterministic 32-byte seed for testing.