From 05d7e8ffeb13f7fb69192027ab3f0f9dd4deacc7 Mon Sep 17 00:00:00 2001 From: Joan Massich Date: Wed, 26 Sep 2018 15:17:51 +0200 Subject: [PATCH 1/2] Add test from #1830 --- testing/python/raises.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/testing/python/raises.py b/testing/python/raises.py index 732e1e82cd1..6738ef9cb3b 100644 --- a/testing/python/raises.py +++ b/testing/python/raises.py @@ -87,6 +87,16 @@ def test_no_raise_message(self): else: assert False, "Expected pytest.raises.Exception" + @pytest.mark.parametrize('example_input,expectation', [ + (3, do_not_raise), + (2, do_not_raise), + (1, do_not_raise), + (0, raises(ZeroDivisionError))]) + def test_do_not_raise(example_input, expectation): + """Test do_not_raise.""" + with expectation: + assert (6 / example_input) is not None + def test_custom_raise_message(self): message = "TEST_MESSAGE" try: From 9024414b7f2351b65292b6933064bbbeb7024bd7 Mon Sep 17 00:00:00 2001 From: Joan Massich Date: Wed, 26 Sep 2018 16:08:48 +0200 Subject: [PATCH 2/2] Add authors --- AUTHORS | 1 + 1 file changed, 1 insertion(+) diff --git a/AUTHORS b/AUTHORS index 9b4b8b8ccdf..bd5016d70af 100644 --- a/AUTHORS +++ b/AUTHORS @@ -103,6 +103,7 @@ Javier Romero Jeff Rackauckas Jeff Widman Jenni Rinker +Joan Massich John Eddie Ayson John Towler Jon Sonesen