From 0b4a328de6775353a34d72b6b5dea1c0aa1de46d Mon Sep 17 00:00:00 2001
From: Massimiliano Torromeo <massimiliano.torromeo@gmail.com>
Date: Tue, 25 May 2021 10:37:16 +0200
Subject: [PATCH] TEST: Use absolute path for the MODPATH assertions in python
 tests

---
 src/tests/pyhbac-test.py       | 2 +-
 src/tests/pysss-test.py        | 2 +-
 src/tests/pysss_murmur-test.py | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/tests/pyhbac-test.py b/src/tests/pyhbac-test.py
index 06163afc50..a0775d4523 100755
--- a/src/tests/pyhbac-test.py
+++ b/src/tests/pyhbac-test.py
@@ -27,7 +27,7 @@
 import tempfile
 
 BUILD_DIR = os.getenv('builddir') or "."
-TEST_DIR = os.getenv('SSS_TEST_DIR') or "."
+TEST_DIR = os.path.abspath(os.getenv('SSS_TEST_DIR') or ".")
 MODPATH = tempfile.mkdtemp(prefix="tp_pyhbac_", dir=TEST_DIR)
 
 
diff --git a/src/tests/pysss-test.py b/src/tests/pysss-test.py
index 30bc074abd..9ecaed9ec6 100755
--- a/src/tests/pysss-test.py
+++ b/src/tests/pysss-test.py
@@ -26,7 +26,7 @@
 import tempfile
 
 BUILD_DIR = os.getenv('builddir') or "."
-TEST_DIR = os.getenv('SSS_TEST_DIR') or "."
+TEST_DIR = os.path.abspath(os.getenv('SSS_TEST_DIR') or ".")
 MODPATH = tempfile.mkdtemp(prefix="tp_pysss_", dir=TEST_DIR)
 
 
diff --git a/src/tests/pysss_murmur-test.py b/src/tests/pysss_murmur-test.py
index 531f8b55f6..89d5077b70 100755
--- a/src/tests/pysss_murmur-test.py
+++ b/src/tests/pysss_murmur-test.py
@@ -25,7 +25,7 @@
 import tempfile
 
 BUILD_DIR = os.getenv('builddir') or "."
-TEST_DIR = os.getenv('SSS_TEST_DIR') or "."
+TEST_DIR = os.path.abspath(os.getenv('SSS_TEST_DIR') or ".")
 MODPATH = tempfile.mkdtemp(prefix="tp_pysss_murmur_", dir=TEST_DIR)
 
 
