[Replicant] [libsamsung-ipc] [PATCH 26/26] tools: move the tests in their own directory

Denis 'GNUtoo' Carikli GNUtoo at cyberdimension.org
Mon Mar 28 20:20:40 UTC 2022


Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo at cyberdimension.org>
---
 tools/Makefile.am                 | 6 +++---
 tools/{ => tests}/ipc-modem.py    | 2 ++
 tools/{ => tests}/nv_data-imei.py | 2 ++
 tools/{ => tests}/nv_data-md5.py  | 2 ++
 4 files changed, 9 insertions(+), 3 deletions(-)
 rename tools/{ => tests}/ipc-modem.py (98%)
 rename tools/{ => tests}/nv_data-imei.py (98%)
 rename tools/{ => tests}/nv_data-md5.py (97%)

diff --git a/tools/Makefile.am b/tools/Makefile.am
index 41e5441..7f51630 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -15,9 +15,9 @@ bin_PROGRAMS = \
 # nv_data-imei in TEST while having it implemented in a single python file
 PY_LOG_COMPILER = $(PYTHON)
 TEST_EXTENSIONS = .py
-TESTS = ipc-modem.py \
-	nv_data-imei.py \
-	nv_data-md5.py
+TESTS = tests/ipc-modem.py \
+	tests/nv_data-imei.py \
+	tests/nv_data-md5.py
 
 ipc_modem_SOURCES = ipc-modem.c
 ipc_modem_LDADD = $(top_builddir)/samsung-ipc/libsamsung-ipc.la
diff --git a/tools/ipc-modem.py b/tools/tests/ipc-modem.py
similarity index 98%
rename from tools/ipc-modem.py
rename to tools/tests/ipc-modem.py
index 0fe76d7..af996ac 100755
--- a/tools/ipc-modem.py
+++ b/tools/tests/ipc-modem.py
@@ -44,6 +44,8 @@ class IpcModem(object):
         # Enable to run tests without automake
         else:
             command_path = os.path.dirname(sys.argv[0]) \
+                + os.sep \
+                + '..'   \
                 + os.sep \
                 + 'ipc-modem'
 
diff --git a/tools/nv_data-imei.py b/tools/tests/nv_data-imei.py
similarity index 98%
rename from tools/nv_data-imei.py
rename to tools/tests/nv_data-imei.py
index c3e9351..cec4e7f 100755
--- a/tools/nv_data-imei.py
+++ b/tools/tests/nv_data-imei.py
@@ -53,6 +53,8 @@ class NvDataImei(object):
         # Enable to run tests without automake
         else:
             command_path = os.path.dirname(sys.argv[0]) \
+                + os.sep \
+                + '..'   \
                 + os.sep \
                 + 'nv_data-imei'
 
diff --git a/tools/nv_data-md5.py b/tools/tests/nv_data-md5.py
similarity index 97%
rename from tools/nv_data-md5.py
rename to tools/tests/nv_data-md5.py
index 54a8ad1..315daee 100755
--- a/tools/nv_data-md5.py
+++ b/tools/tests/nv_data-md5.py
@@ -39,6 +39,8 @@ class NvDataMD5(object):
         # Enable to run tests without automake
         else:
             command_path = os.path.dirname(sys.argv[0]) \
+                + os.sep \
+                + '..'   \
                 + os.sep \
                 + 'nv_data-md5'
 
-- 
2.35.1



More information about the Replicant mailing list