From a44d2422a7907b06c97b1cff88a4b287cf05cc97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20P=2E=20D=C3=BCrholt?= Date: Sun, 15 Sep 2024 11:28:11 +0200 Subject: [PATCH] Update test/exceptions/test_errors.py Co-authored-by: Max Balandat --- test/exceptions/test_errors.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/exceptions/test_errors.py b/test/exceptions/test_errors.py index 6b79400b94..e0c42685eb 100644 --- a/test/exceptions/test_errors.py +++ b/test/exceptions/test_errors.py @@ -54,5 +54,5 @@ def test_OptimizationTimeoutError(self): def test_OptimizationGradientError(self): error = OptimizationGradientError("message", current_x=np.array([1.0])) self.assertTrue(np.array_equal(error.current_x, np.array([1.0]))) - with self.assertRaises(OptimizationGradientError): + with self.assertRaisesRegex(OptimizationGradientError, "message"): raise error