assert_state_matches

Macro assert_state_matches 

Source
macro_rules! assert_state_matches {
    ($harness:expr, $($field:tt).+, $pattern:pat $(if $guard:expr)?) => { ... };
}
Expand description

Assert that a field of the harness state matches a pattern.

§Example

use tui_dispatch::testing::{TestHarness, assert_state_matches};

assert_state_matches!(harness, connection_status, ConnectionStatus::Connected { .. });