From 5b8f7473d022031400e8d2da0605b3f779d32686 Mon Sep 17 00:00:00 2001 From: Ace Date: Wed, 2 Dec 2020 00:59:00 +0100 Subject: [PATCH] adapted tests --- inkycal/tests/inkycal_image_test.py | 14 +++++++------- inkycal/tests/inkycal_slideshow_test.py | 22 +++++++++++++++------- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/inkycal/tests/inkycal_image_test.py b/inkycal/tests/inkycal_image_test.py index 87cc987..8612b24 100644 --- a/inkycal/tests/inkycal_image_test.py +++ b/inkycal/tests/inkycal_image_test.py @@ -11,7 +11,7 @@ tests = [ "config": { "size": [400,200], "path": test_path, - "use_colour": True, + "palette": "bwr", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -23,7 +23,7 @@ tests = [ "config": { "size": [800,500], "path": test_path, - "use_colour": False, + "palette": "bwy", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -35,7 +35,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bw", "autoflip": False, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -47,7 +47,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bwr", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -59,7 +59,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bwy", "autoflip": True, "orientation": "horizontal", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -71,7 +71,7 @@ tests = [ "config": { "size": [500, 800], "path": test_path, - "use_colour": True, + "palette": "bw", "autoflip": True, "orientation": "vertical", "padding_x": 0, "padding_y": 0, "fontsize": 12, "language": "en" @@ -83,7 +83,7 @@ tests = [ "config": { "size": [500, 800], "path": test_path, - "use_colour": True, + "palette": "bwr", "autoflip": True, "orientation": "vertical", "padding_x": 20, "padding_y": 20, "fontsize": 12, "language": "en" diff --git a/inkycal/tests/inkycal_slideshow_test.py b/inkycal/tests/inkycal_slideshow_test.py index b03433f..75d2550 100644 --- a/inkycal/tests/inkycal_slideshow_test.py +++ b/inkycal/tests/inkycal_slideshow_test.py @@ -11,7 +11,7 @@ tests = [ "config": { "size": [400,200], "path": test_path, - "use_colour": True, + "palette": "bwy", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -23,7 +23,7 @@ tests = [ "config": { "size": [800,500], "path": test_path, - "use_colour": False, + "palette": "bw", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -35,7 +35,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bwr", "autoflip": False, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -47,7 +47,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bwy", "autoflip": True, "orientation": "vertical", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -59,7 +59,7 @@ tests = [ "config": { "size": [400,100], "path": test_path, - "use_colour": True, + "palette": "bwy", "autoflip": True, "orientation": "horizontal", "padding_x": 10, "padding_y": 10, "fontsize": 12, "language": "en" @@ -71,7 +71,7 @@ tests = [ "config": { "size": [500, 800], "path": test_path, - "use_colour": True, + "palette": "bw", "autoflip": True, "orientation": "vertical", "padding_x": 0, "padding_y": 0, "fontsize": 12, "language": "en" @@ -83,7 +83,7 @@ tests = [ "config": { "size": [500, 800], "path": test_path, - "use_colour": True, + "palette": "bwr", "autoflip": True, "orientation": "vertical", "padding_x": 20, "padding_y": 20, "fontsize": 12, "language": "en" @@ -104,5 +104,13 @@ class module_test(unittest.TestCase): module.generate_image() print('OK') + def test_switch_to_next_image(self): + print(f'testing switching to next images..') + module = Module(tests[0]) + module.generate_image() + module.generate_image() + module.generate_image() + print('OK') + if __name__ == '__main__': unittest.main()