summaryrefslogtreecommitdiff
path: root/tests/topotests/lib/fe_client.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/topotests/lib/fe_client.py')
-rwxr-xr-xtests/topotests/lib/fe_client.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/topotests/lib/fe_client.py b/tests/topotests/lib/fe_client.py
index ec643bb0bf..07059ccf3a 100755
--- a/tests/topotests/lib/fe_client.py
+++ b/tests/topotests/lib/fe_client.py
@@ -321,12 +321,18 @@ class Session:
while True:
logging.debug("Waiting for Notify Message")
mhdr, mfixed, mdata = self.recv_native_msg()
- assert mdata[-1] == 0
- result = mdata[:-1].decode("utf-8")
if mhdr[HDR_FIELD_CODE] == MSG_CODE_NOTIFY:
logging.debug("Received Notify Message: %s: %s", mfixed, mdata)
else:
raise Exception(f"Received NON-NOTIFY Message: {mfixed}: {mdata}")
+
+ vsplit = mhdr[HDR_FIELD_VSPLIT]
+ assert mdata[vsplit - 1] == 0
+ xpath = mdata[: vsplit - 1].decode("utf-8")
+
+ assert mdata[-1] == 0
+ result = mdata[vsplit:-1].decode("utf-8")
+
if not xpaths:
return result
js = json.loads(result)