improve unit-testing

use config class which reads from .env file
remove obsolete functions
update requirements
This commit is contained in:
aceisace
2023-01-11 22:24:39 +01:00
parent 9fa2f4a003
commit 8e754cb6cd
16 changed files with 237 additions and 197 deletions

View File

@@ -1,8 +1,6 @@
#!python3
"""
Main test (main)
Copyright by aceisace
Inkycal main unittest
"""
import os
import unittest
@@ -63,7 +61,7 @@ class ModuleTest(unittest.TestCase):
# Check if settings.json file exists in current directory
if not os.path.exists("settings.json"):
# Create temporary json settings file with the config from above
with open('settings.json', mode="w") as file:
with open('settings.json', mode="w", encoding="utf-8") as file:
file.write(test_config)
print('testing Inkycal in non-render-mode...', end="")
inky = Inkycal('settings.json', render=False)