diff mbox series

[03/10] rteval: Use f-strings in cputopology

Message ID 20230601192928.809434-3-ashelat@redhat.com
State New
Headers show
Series [01/10] rteval: Use f-strings in rtevalclient.py | expand

Commit Message

Anubhav Shelat June 1, 2023, 7:29 p.m. UTC
Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
---
 rteval/sysinfo/cputopology.py | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/rteval/sysinfo/cputopology.py b/rteval/sysinfo/cputopology.py
index ced7e1f295b7..2bb632312320 100644
--- a/rteval/sysinfo/cputopology.py
+++ b/rteval/sysinfo/cputopology.py
@@ -124,9 +124,7 @@  def unit_test(rootdir):
         x.saveFormatFileEnc('-', 'UTF-8', 1)
 
         print(" ---- getCPUcores() / getCPUscokets() ---- ")
-        print("CPU cores: %i (online: %i) - CPU sockets: %i" % (cputop.cpu_getCores(False),
-                                                                cputop.cpu_getCores(True),
-                                                                cputop.cpu_getSockets()))
+        print(f"CPU cores: {cputop.cpu_getCores(False)} (online: {cputop.cpu_getCores(True)}) - CPU sockets: {cputop.cpu_getSockets()}")
         return 0
     except Exception as e:
         # import traceback