#![cfg_attr(not(feature = "std"), no_std)]
#![cfg_attr(wasm_bindgen_unstable_test_coverage, feature(coverage_attribute))]
#![cfg_attr(target_feature = "atomics", feature(thread_local))]
#![deny(missing_docs)]
extern crate alloc;
pub use wasm_bindgen_test_macro::{wasm_bindgen_bench, wasm_bindgen_test};
#[cfg(all(test, feature = "gg-alloc"))]
#[global_allocator]
static A: gg_alloc::GgAlloc<std::alloc::System> = gg_alloc::GgAlloc::new(std::alloc::System);
#[macro_export]
macro_rules! console_error {
($($arg:tt)*) => (
$crate::__rt::console_error(&format_args!($($arg)*))
)
}
#[macro_export]
macro_rules! console_log {
($($arg:tt)*) => (
$crate::__rt::console_log(&format_args!($($arg)*))
)
}
#[macro_export]
macro_rules! wasm_bindgen_test_configure {
(run_in_browser $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_RUN_IN_BROWSER: [u8; 1] = [0x01];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_worker $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_RUN_IN_DEDICATED_WORKER: [u8; 1] = [0x02];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_dedicated_worker $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_RUN_IN_DEDICATED_WORKER: [u8; 1] = [0x02];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_shared_worker $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_RUN_IN_SHARED_WORKER: [u8; 1] = [0x03];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_service_worker $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_RUN_IN_SERVICE_WORKER: [u8; 1] = [0x04];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_node_experimental $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_run_in_node_experimental: [u8; 1] = [0x05];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
(run_in_emscripten $($others:tt)*) => (
const _: () = {
#[link_section = "__wasm_bindgen_test_unstable"]
#[cfg(target_arch = "wasm32")]
pub static __WBG_TEST_run_in_emscripten: [u8; 1] = [0x06];
$crate::wasm_bindgen_test_configure!($($others)*);
};
);
() => ()
}
#[path = "rt/mod.rs"]
pub mod __rt;
#[cfg(target_arch = "wasm32")]
#[cfg_attr(wasm_bindgen_unstable_test_coverage, coverage(off))]
mod coverage;
pub use __rt::criterion::Criterion;
pub use __rt::web_time::Instant;