diff --git a/traits/tests/test_configure_traits.py b/traits/tests/test_configure_traits.py index e192351b5..28dfca975 100644 --- a/traits/tests/test_configure_traits.py +++ b/traits/tests/test_configure_traits.py @@ -155,4 +155,8 @@ def test_edit_not_given(self): warnings.simplefilter("always", DeprecationWarning) model.configure_traits() mock_view.assert_called_once() - self.assertEqual(len(captured_warnings), 0) + + all_warnings = "".join( + str(warning.message) for warning in captured_warnings + ) + self.assertNotIn("edit argument", all_warnings)