chromium/third_party/rust/chromium_crates_io/vendor/rstest-0.17.0/tests/resources/rstest/single/async_awt_global.rs

use rstest::*;

#[fixture]
async fn fixture() -> u32 {
    42
}

#[rstest]
#[awt]
async fn should_pass(#[future] fixture: u32) {
    assert_eq!(fixture, 42);
}

#[rstest]
#[awt]
async fn should_fail(#[future] fixture: u32) {
    assert_ne!(fixture, 42);
}

#[rstest]
#[awt]
#[should_panic]
async fn should_panic_pass(#[future] fixture: u32) {
    panic!(format!("My panic -> fixture = {}", fixture));
}

#[rstest]
#[awt]
#[should_panic]
async fn should_panic_fail(#[future] fixture: u32) {
    assert_eq!(fixture, 42);
}