GLib.test_set_nonfatal_assertions

function test_set_nonfatal_assertions(): void {
    // Gjs wrapper for g_test_set_nonfatal_assertions()
}
  

Changes the behaviour of g_assert_cmpstr(), g_assert_cmpint(), g_assert_cmpuint(), g_assert_cmphex(), g_assert_cmpfloat(), g_assert_true(), g_assert_false(), g_assert_null(), g_assert_no_error(), g_assert_error(), g_test_assert_expected_messages() and the various g_test_trap_assert_*() macros to not abort to program, but instead call GLib.test_fail and continue. (This also changes the behavior of GLib.test_fail so that it will not cause the test program to abort after completing the failed test.)

Note that the g_assert_not_reached() and g_assert() are not affected by this.

This function can only be called after GLib.test_init.

Since 2.38