### Function Macro

# GLib test_trap_assert_stderr

since: 2.16

#### Declaration

    #define g_test_trap_assert_stderr (
      serrpattern
    )

#### Description

Assert that the stderr output of the last test subprocess matches `serrpattern`. See g_test_trap_subprocess().

This is sometimes used to test situations that are formally considered to be undefined behaviour, like code that hits a `g_assert()` or g_error(). In these situations you should skip the entire test, including the call to g_test_trap_subprocess(), unless `g_test_undefined()` returns `TRUE` to indicate that undefined behaviour may be tested.

Available since: 2.16

This function is not directly available to language bindings.

#### Parameters

`serrpattern`

  Type: `-`

  A glob-style [pattern][glib-Glob-style-pattern-matching]