On 5/29/25 00:04, ALOK TIWARI wrote:


On 27-05-2025 21:49, Bui Quang Minh wrote:
+def main():
+    with NetDrvEpEnv(__file__, nsim_test=False) as cfg:
+        cfg.bin_local = path.abspath(path.dirname(__file__)
+                            + "/../../../drivers/net/hw/xsk_receive")
+        cfg.bin_remote = cfg.remote.deploy(cfg.bin_local)
+
+        server_cmd = f"{cfg.bin_remote} -s -i {cfg.remote_ifname} "
+        server_cmd += f"-r {cfg.remote_addr_v["4"]} -l {cfg.addr_v["4"]}"
+        client_cmd = f"{cfg.bin_local} -c -r {cfg.remote_addr_v["4"]} "
+        client_cmd += f"-l {cfg.addr_v["4"]}"
+
+        ksft_run(globs=globals(), case_pfx={"test_"}, args=(cfg, server_cmd, client_cmd))
+    ksft_exit()

SyntaxError ?
inner ["4"] uses double quotes, which clash with the outer double quotes of the f-string

This works just fine because the ["4"] is inside {}. But I can fix this to avoid confusion.

Thanks,
Quang Minh.


Reply via email to