mirror of
https://github.com/dylanaraps/pywal.git
synced 2024-11-29 03:13:47 +01:00
22 lines
561 B
Python
22 lines
561 B
Python
"""Test image functions."""
|
|
import unittest
|
|
|
|
from pywal import wal
|
|
|
|
|
|
class TestImage(unittest.TestCase):
|
|
"""Test image functions."""
|
|
def test_get_img(self):
|
|
"""> Validate image file."""
|
|
result = wal.get_image("tests/test_files/test.jpg")
|
|
self.assertEqual(result, "tests/test_files/test.jpg")
|
|
|
|
def test_get_img_dir(self):
|
|
"""> Validate image directory."""
|
|
result = wal.get_image("tests/test_files")
|
|
self.assertEqual(result, "tests/test_files/test.jpg")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
unittest.main()
|