2023-12-21 14:13:31 +03:00
|
|
|
from __future__ import annotations
|
2024-01-20 14:23:03 +03:00
|
|
|
|
2020-02-25 12:57:27 +03:00
|
|
|
from .helper import assert_image_equal, assert_image_similar, hopper
|
2017-11-17 22:47:05 +03:00
|
|
|
|
|
|
|
|
2024-01-27 07:19:43 +03:00
|
|
|
def check_upload_equal() -> None:
|
2020-02-25 12:57:27 +03:00
|
|
|
result = hopper("P").convert("RGB")
|
|
|
|
target = hopper("RGB")
|
|
|
|
assert_image_equal(result, target)
|
2017-11-17 22:47:05 +03:00
|
|
|
|
2020-02-25 12:57:27 +03:00
|
|
|
|
2024-01-27 07:19:43 +03:00
|
|
|
def check_upload_similar() -> None:
|
2020-02-25 12:57:27 +03:00
|
|
|
result = hopper("P").convert("RGB")
|
|
|
|
target = hopper("RGB")
|
|
|
|
assert_image_similar(result, target, 0)
|