osmith submitted this change.

View Change



2 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.

Approvals: pespin: Looks good to me, but someone else must approve fixeria: Looks good to me, approved laforge: Looks good to me, but someone else must approve Jenkins Builder: Verified
testenv: make it pass 'ruff check' linter

I've added 'ruff check' to my pre-commit script. Make it pass initially,
so it can detect future bugs. The missing f-string is a bug that causes
ggsn testsuites with a custom kernel path to not work.

Change-Id: I3e5cd05ce0aa241509d77391c5ed64e618f385ba
---
M _testenv/testenv/podman.py
M _testenv/testenv/testsuite.py
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/_testenv/testenv/podman.py b/_testenv/testenv/podman.py
index 16db400..1281b3b 100644
--- a/_testenv/testenv/podman.py
+++ b/_testenv/testenv/podman.py
@@ -254,7 +254,7 @@
cmd += ["--volume", "/dev/kvm:/dev/kvm"]
if os.path.islink(testenv.custom_kernel_path):
dest = os.readlink(testenv.custom_kernel_path)
- cmd += ["--volume", "{dest}:{dest}:ro"]
+ cmd += ["--volume", f"{dest}:{dest}:ro"]

cmd += [
"--volume",
diff --git a/_testenv/testenv/testsuite.py b/_testenv/testenv/testsuite.py
index 0fa42ab..9b28668 100644
--- a/_testenv/testenv/testsuite.py
+++ b/_testenv/testenv/testsuite.py
@@ -225,7 +225,7 @@
try:
with open(path, "r") as h:
return h.readline().rstrip()
- except:
+ except: # noqa
# File may not exist, e.g. if test was stopped
return None


To view, visit change 38778. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I3e5cd05ce0aa241509d77391c5ed64e618f385ba
Gerrit-Change-Number: 38778
Gerrit-PatchSet: 3
Gerrit-Owner: osmith <osmith@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: laforge <laforge@osmocom.org>
Gerrit-Reviewer: osmith <osmith@sysmocom.de>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>