traits icon indicating copy to clipboard operation
traits copied to clipboard

Tests fail with latest Traits and TraitsUI from PyPI

Open mdickinson opened this issue 1 year ago • 1 comments

I'm seeing a test failure with the latest Traits and TraitsUI from PyPI, on Python 3.11. (I haven't tested with other Python versions, but it likely affects those, too.)

Steps to reproduce:

  • Create a new Python 3.11 venv, and activate it.
  • Run pip install traits traitsui
  • Run python -m unittest discover -v traits

Expected results: the test suite runs to completion.

Actual results: we get the following test failure:

======================================================================
FAIL: test_edit_not_given (traits.tests.test_configure_traits.TestConfigureTraits.test_edit_not_given)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/mdickinson/.venvs/traits/lib/python3.11/site-packages/traits/tests/test_configure_traits.py", line 158, in test_edit_not_given
    self.assertEqual(len(captured_warnings), 0)
AssertionError: 2 != 0

----------------------------------------------------------------------

This is likely to be an overzealous test, but as well as tightening this test, we should investigate what the warnings are, where they're coming from, and how we can fix them.

mdickinson avatar Jun 26 '23 12:06 mdickinson