Skip to content

Commit

Permalink
fix importlib.metadata:EntryPoint on python3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
schettino72 committed Apr 13, 2022
1 parent f4a4e6c commit 78b20f3
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 2 additions & 0 deletions doc/dictionary.txt
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ args
atime
attr
auth
auto1
autoclass
autoload
automethod
Expand Down Expand Up @@ -314,6 +315,7 @@ html
https
hunspell
img
importlib
ini
init
initializer
Expand Down
8 changes: 7 additions & 1 deletion tests/test_plugin.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
from importlib.metadata import EntryPoint
import sys
from unittest.mock import Mock

import pytest

from doit.plugin import PluginEntry, PluginDict


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


class TestPluginEntry(object):
def test_repr(self):
plugin = PluginEntry('category1', 'name1', 'mock:Mock')
Expand Down

0 comments on commit 78b20f3

Please sign in to comment.