mirror of
https://github.com/enpaul/kodak.git
synced 2024-11-14 02:27:24 +00:00
Fix missing repo metadata
Add missing entries to __about__ Add missing tests/__init__ file Add missing tests to test_about Fix trailing whitespace in openapi
This commit is contained in:
parent
e94e239938
commit
1c1de0c241
@ -1,6 +1,9 @@
|
||||
"""Programatically accessible project metadata"""
|
||||
|
||||
|
||||
__title__ = "awesome-template"
|
||||
__title__ = "imagemonk"
|
||||
__version__ = "0.0.0"
|
||||
__authors__ = ["Ethan Paul <e@enp.one>"]
|
||||
__authors__ = ["Ethan Paul <24588726+enpaul@users.noreply.github.com>"]
|
||||
__license__ = "MIT"
|
||||
__summary__ = "HTTP server for uploading images and generating thumbnails"
|
||||
__url__ = "https://github.com/mocproject/imagemonk/"
|
||||
|
0
tests/__init__.py
Normal file
0
tests/__init__.py
Normal file
@ -9,14 +9,25 @@ from imagemonk import __about__
|
||||
def test_about():
|
||||
"""Test metadata values"""
|
||||
|
||||
with (Path(__file__).parent.parent / "pyproject.toml").open() as infile:
|
||||
about = toml.load(infile)
|
||||
with (Path(__file__).resolve().parent.parent / "pyproject.toml").open() as infile:
|
||||
pyproject = toml.load(infile)
|
||||
|
||||
assert about["tool"]["poetry"]["name"] == __about__.__title__
|
||||
assert about["tool"]["poetry"]["version"] == __about__.__version__
|
||||
assert all(
|
||||
author in about["tool"]["poetry"]["authors"] for author in __about__.__authors__
|
||||
assert pyproject["tool"]["poetry"]["name"] == __about__.__title__
|
||||
assert pyproject["tool"]["poetry"]["version"] == __about__.__version__
|
||||
assert pyproject["tool"]["poetry"]["license"] == __about__.__license__
|
||||
assert pyproject["tool"]["poetry"]["description"] == __about__.__summary__
|
||||
assert pyproject["tool"]["poetry"]["repository"] == __about__.__url__
|
||||
assert (
|
||||
all(
|
||||
item in __about__.__authors__
|
||||
for item in pyproject["tool"]["poetry"]["authors"]
|
||||
)
|
||||
assert all(
|
||||
author in __about__.__authors__ for author in about["tool"]["poetry"]["authors"]
|
||||
is True
|
||||
)
|
||||
assert (
|
||||
all(
|
||||
item in pyproject["tool"]["poetry"]["authors"]
|
||||
for item in __about__.__authors__
|
||||
)
|
||||
is True
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user