From 21df1491010c262f574708654c8c4e2df1c70053 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mat=C4=9Bj=20T=C3=BD=C4=8D?= Date: Sun, 4 Sep 2022 12:55:18 +0200 Subject: [PATCH] Add autotailor unit test stub. --- tests/utils/test_autotailor.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 tests/utils/test_autotailor.py diff --git a/tests/utils/test_autotailor.py b/tests/utils/test_autotailor.py new file mode 100644 index 00000000000..5cf31b542f2 --- /dev/null +++ b/tests/utils/test_autotailor.py @@ -0,0 +1,12 @@ +import importlib + + +def import_arbitrary_file_as_module(path, module_name): + spec = importlib.util.spec_from_loader( + module_name, importlib.machinery.SourceFileLoader(module_name, path)) + module = importlib.util.module_from_spec(spec) + spec.loader.exec_module(module) + return module + + +autotailor = import_arbitrary_file_as_module("utils/autotailor", "autotailor")