revsys / django-test-plus

Useful additions to Django's default TestCase
https://django-test-plus.readthedocs.io
BSD 3-Clause "New" or "Revised" License
612 stars 62 forks source link

Use packaging.version where available #210

Closed offbyone closed 5 months ago

offbyone commented 5 months ago

Fixes: https://github.com/revsys/django-test-plus/issues/209

offbyone commented 5 months ago

Note, I could not run the tests locally, so I'm hoping CI bears out my work here:

  File "/Users/offby1/projects/django-test-plus/.venv/lib/python3.12/site-packages/_pytest/config/__init__.py", line 1592, in getini
    self._inicache[name] = val = self._getini(name)
                                 ^^^^^^^^^^^^^^^^^^
  File "/Users/offby1/projects/django-test-plus/.venv/lib/python3.12/site-packages/_pytest/config/__init__.py", line 1651, in _getini
    return self._getini_unknown_type(name, type, value)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/offby1/projects/django-test-plus/.venv/lib/python3.12/site-packages/_pytest/config/__init__.py", line 1599, in _getini_unknown_type
    raise ValueError(msg, value)  # pragma: no cover
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: ('unknown configuration type: pathlist', 'test_project/')

(I'm not sure what's going on there, and I'll only dig into it if I need to spend a bunch of iterations on this :) )

offbyone commented 5 months ago

211 will allow these tests to run

jefftriplett commented 5 months ago

I think we could safely packaging; python_version >= '3.7' to setup.cfg::setup_requires.

(side-note: I don't see a reason to not drop 3.6 and 3.7 if we are going to do a major upgrade)

jefftriplett commented 5 months ago

@offbyone thank you!