Skip to content

Commit

Permalink
Remove use of pkg_resources
Browse files Browse the repository at this point in the history
  • Loading branch information
sgillies committed Mar 2, 2024
1 parent 5c95560 commit 3bc6bbe
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ New features:

Bug fixes:

- Use of pkg_resources in test_rio_info.py has been eliminated.
- gzip, tar, and zip archive URIs containing drive letters were not always
parsed properly on Windows, but are now (#1334).

Expand Down
8 changes: 6 additions & 2 deletions tests/test_fio_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@


import json
from pkg_resources import iter_entry_points
import re
import sys

from click.testing import CliRunner
import pytest

if sys.version_info < (3, 10):
from importlib_metadata import entry_points
else:
from importlib.metadata import entry_points

from fiona.fio.main import main_group


Expand Down Expand Up @@ -41,7 +45,7 @@ def test_info_bounds(path_coutwildrnp_shp):
def test_all_registered():
"""Make sure all the subcommands are actually registered to the main CLI
group."""
for ep in iter_entry_points('fiona.fio_commands'):
for ep in entry_points(group="fiona.fio_commands"):
assert ep.name in main_group.commands


Expand Down

0 comments on commit 3bc6bbe

Please # to comment.