diff --git a/test/__init__.py b/test/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/test/test_aspect.py b/test/test_aspect.py new file mode 100644 index 0000000..f19afa9 --- /dev/null +++ b/test/test_aspect.py @@ -0,0 +1,17 @@ + +from minfo import MediaInfo, Ratio, Resolution + +def test_square_source(): + info = MediaInfo() + info.general = { + + } + info.video = { + "Width": 576, + "Height": 576, + "DisplayAspectRatio": 1.778 + } + info.determine_aspect_properties() + + assert info.resolution == Resolution(576, 576) + assert info.pixel_aspect_ratio == Ratio(16, 9)