iota_common/lib.rs
1// Copyright (c) Mysten Labs, Inc.
2// Modifications Copyright (c) 2024 IOTA Stiftung
3// SPDX-License-Identifier: Apache-2.0
4
5#[cfg(not(target_arch = "wasm32"))]
6pub mod backoff;
7pub mod logging;
8pub mod random;
9#[cfg(not(target_arch = "wasm32"))]
10pub mod random_util;
11#[cfg(not(target_arch = "wasm32"))]
12pub mod stream_ext;
13#[cfg(not(target_arch = "wasm32"))]
14pub mod sync;
15pub mod try_iterator_ext;
16#[cfg(not(target_arch = "wasm32"))]
17pub use random_util::tempdir;
18
19#[inline(always)]
20pub fn in_test_configuration() -> bool {
21 cfg!(msim) || cfg!(debug_assertions)
22}