- Qt 6.9
- Qt Test
- C++ Classes
- QtTestLib
- ThrowOnFailDisabler
- Qt 6.9.3 Reference Documentation

# QTest::ThrowOnFailDisabler Class

class QTest::ThrowOnFailDisabler

Header: | `#include <ThrowOnFailDisabler>`
Since: | Qt 6.8

- List of all members, including inherited members

## Public Functions

| ThrowOnFailDisabler()
| ~ThrowOnFailDisabler()

## Detailed Description

RAII class around setThrowOnFail().

## Member Function Documentation

### ThrowOnFailDisabler::ThrowOnFailDisabler()

Constructor. Calls `setThrowOnFail(false)`.

### `[noexcept]` ThrowOnFailDisabler::~ThrowOnFailDisabler()

Destructor. Calls `setThrowOnFail(true)`.