diff options
author | Alessandro Zanni <[email protected]> | 2024-10-10 21:44:17 +0200 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2024-10-11 15:59:53 -0700 |
commit | 6ea8a1c28fd36179fc66e088060b11515c8508b7 (patch) | |
tree | 64a78ae489c12b055286d9565c9fa6bdfc634b05 | |
parent | 1d7b2ce43d2c22a21dadaf689cb36a69570346a6 (diff) |
selftests: net/rds: add module not found
This fix solves this error, when calling kselftest with targets "net/rds":
The error was found by running tests manually with the command:
make kselftest TARGETS="net/rds"
The patch also specifies to import ip() function from the utils module.
Signed-off-by: Alessandro Zanni <[email protected]>
Reviewed-by: Allison Henderson <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
-rwxr-xr-x | tools/testing/selftests/net/rds/test.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/testing/selftests/net/rds/test.py b/tools/testing/selftests/net/rds/test.py index e6bb109bcead..4a7178d11193 100755 --- a/tools/testing/selftests/net/rds/test.py +++ b/tools/testing/selftests/net/rds/test.py @@ -14,8 +14,11 @@ import sys import atexit from pwd import getpwuid from os import stat -from lib.py import ip +# Allow utils module to be imported from different directory +this_dir = os.path.dirname(os.path.realpath(__file__)) +sys.path.append(os.path.join(this_dir, "../")) +from lib.py.utils import ip libc = ctypes.cdll.LoadLibrary('libc.so.6') setns = libc.setns |