summaryrefslogtreecommitdiff
path: root/test/selfmount.py
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-09-29 00:01:04 -0300
committerGabriel Schneider <[email protected]>2026-10-01 00:12:15 -0300
commit64b6a0dbdaab4b314ccbce667709d71a8561daf0 (patch)
treeceb955449a4458675e7d3bccca4565bd469039da /test/selfmount.py
parentb71a9051006f88052d240e521046428c4e1c5e15 (diff)
downloadpardes-64b6a0dbdaab4b314ccbce667709d71a8561daf0.tar.gz
pardes-64b6a0dbdaab4b314ccbce667709d71a8561daf0.zip
The tree serves the layout: /layout, /tag and /col/<n>/tag
A script could not see where the panes sit or edit the tags a person clicks in. /layout lists each column, its index, x and width in cells, current or not, empty or full, and its panes' serials, then the active column; /tag is the workspace tag and /col/<n>/tag a column's, read and written as a pane tag is (one line: a newline written in is a space, and a truncating write drops the one ending it); /index's lines end with the pane's column; the log says newcol <n> and delcol <n>. acme serves no column files, and the docs say so. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'test/selfmount.py')
-rw-r--r--test/selfmount.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/selfmount.py b/test/selfmount.py
index cc889a93..90960bed 100644
--- a/test/selfmount.py
+++ b/test/selfmount.py
@@ -75,7 +75,7 @@ def run(binary):
mount = f'/mnt/9p/pardes/{name}'
with Client(sock) as client:
index = client.read('/index').decode()
- rows = [row.split(maxsplit=3) for row in index.splitlines()]
+ rows = [row.rsplit(maxsplit=1)[0].split(maxsplit=3) for row in index.splitlines()]
first = rows[0][0]
# A Look at the tree's own index: realpath, stat and read all go
# out through 9ns and back in, and the write returns when the
@@ -84,7 +84,7 @@ def run(binary):
client.write('/look', (mount + '/index\n').encode())
took = time.monotonic() - started
check(took < 5, f'look at the mounted index returned ({took:.2f}s)')
- rows = [row.split(maxsplit=3) for row in client.read('/index').decode().splitlines()]
+ rows = [row.rsplit(maxsplit=1)[0].split(maxsplit=3) for row in client.read('/index').decode().splitlines()]
opened = [row for row in rows if len(row) == 4 and row[3] == mount + '/index']
check(len(opened) == 1, 'a pane opened on the mounted index')
if opened:
@@ -94,7 +94,7 @@ def run(binary):
# and a Save: the save writes back through the mount into pane 1,
# and the exec returns once it has.
client.write('/look', f'{mount}/pane/{first}/body\n'.encode())
- rows = [row.split(maxsplit=3) for row in client.read('/index').decode().splitlines()]
+ rows = [row.rsplit(maxsplit=1)[0].split(maxsplit=3) for row in client.read('/index').decode().splitlines()]
mirror = [row for row in rows if len(row) == 4 and row[3] == f'{mount}/pane/{first}/body']
check(len(mirror) == 1, 'a pane opened on the mounted body')
if mirror: