Skip to main content

assert_category

Function assert_category 

Source
pub fn assert_category<E: DomainError + ?Sized>(
    err: &E,
    expected: ErrorCategory,
)
Expand description

Assert that err’s category equals expected.

§Panics

Panics with the actual category and code if they differ.