From fd63d47a2bb908bb0ac4638e7422bdeabcafb9d7 Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Tue, 14 May 2024 16:28:19 -0400 Subject: [PATCH] nix pkg_resources (#49) --- setup.cfg | 1 + twoaxistracking/tests/test_twoaxistracking.py | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/setup.cfg b/setup.cfg index 352f219..f6fd31a 100644 --- a/setup.cfg +++ b/setup.cfg @@ -31,6 +31,7 @@ install_requires = test = pytest pytest-cov + packaging doc = sphinx==4.4.0 myst-nb==0.16.0 diff --git a/twoaxistracking/tests/test_twoaxistracking.py b/twoaxistracking/tests/test_twoaxistracking.py index ef4014d..a764a06 100644 --- a/twoaxistracking/tests/test_twoaxistracking.py +++ b/twoaxistracking/tests/test_twoaxistracking.py @@ -1,4 +1,4 @@ -from pkg_resources import parse_version +from packaging.version import Version import twoaxistracking @@ -6,5 +6,5 @@ def test___version__(): # check that the version string is determined correctly. # if the version string is messed up for some reason, it should be # '0+unknown', which is not greater than '0.0.1'. - version = parse_version(twoaxistracking.__version__) - assert version > parse_version('0.0.1') + version = Version(twoaxistracking.__version__) + assert version > Version('0.0.1')