From b4fd0441499e56f8eb9108bc313098dd2f957117 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Thu, 19 Jul 2018 17:41:57 +0200 Subject: [PATCH] Documented the catchExceptions() method --- testing.rst | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/testing.rst b/testing.rst index a2cc8f2c1e2..d7d5f2038ae 100644 --- a/testing.rst +++ b/testing.rst @@ -521,6 +521,19 @@ will no longer be followed:: $client->followRedirects(false); +Reporting Exceptions +~~~~~~~~~~~~~~~~~~~~ + +.. versionadded:: 3.4 + The ``catchExceptions()`` method was introduced in Symfony 3.4. + +Debugging exceptions in functional tests may be difficult because by default +they are caught and you need to look at the logs to see which exception was +thrown. Disabling catching of exceptions in the test client allows the exception +to be reported by PHPUnit:: + + $client->catchExceptions(false); + .. index:: single: Tests; Crawler