From a76aa6ff8044705302f07aeaf1db4f6364844911 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 30 Jan 2024 20:37:18 +0000 Subject: [PATCH] [8.0.x] fix incorrect examples for group_contains (#11897) Co-authored-by: John Litborn <11260241+jakkdl@users.noreply.github.com> --- doc/en/how-to/assert.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/en/how-to/assert.rst b/doc/en/how-to/assert.rst index 5c7d125fe..7b0277446 100644 --- a/doc/en/how-to/assert.rst +++ b/doc/en/how-to/assert.rst @@ -154,7 +154,7 @@ method to test for exceptions returned as part of an :class:`ExceptionGroup`: .. code-block:: python def test_exception_in_group(): - with pytest.raises(RuntimeError) as excinfo: + with pytest.raises(ExceptionGroup) as excinfo: raise ExceptionGroup( "Group message", [ @@ -176,7 +176,7 @@ exception at a specific level; exceptions contained directly in the top .. code-block:: python def test_exception_in_group_at_given_depth(): - with pytest.raises(RuntimeError) as excinfo: + with pytest.raises(ExceptionGroup) as excinfo: raise ExceptionGroup( "Group message", [