1
0
mirror of https://github.com/enpaul/kodak.git synced 2024-11-14 18:46:50 +00:00
kodak/tests/test_about.py

23 lines
644 B
Python
Raw Normal View History

2020-09-16 07:41:53 +00:00
"""Test that metadata module matches pyproject"""
from pathlib import Path
import toml
from imagemonk import __about__
def test_about():
"""Test metadata values"""
with (Path(__file__).parent.parent / "pyproject.toml").open() as infile:
about = 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 all(
author in __about__.__authors__ for author in about["tool"]["poetry"]["authors"]
)