@@ -48,7 +48,7 @@ run_state() {
4848}
4949
5050working_marker=$' \342\201\240\342\200\213\342\201\240 '
51- idle_marker =$' \342\201\240\342\200\214\342\201\240 '
51+ stopped_marker =$' \342\201\240\342\200\214\342\201\240 '
5252input_marker=$' \342\201\240\342\200\215\342\201\240 '
5353
5454run_state working > /dev/null
@@ -69,11 +69,11 @@ grep -Fq -- "tab-action --surface surface-id --action rename --title surface${in
6969grep -Fq -- ' workspace-action --workspace workspace-id --action rename --title workspace' " $calls_file "
7070
7171: > " $calls_file "
72- MOCK_SURFACE_TITLE=" surface${idle_marker } " run_state clear > /dev/null
72+ MOCK_SURFACE_TITLE=" surface${stopped_marker } " run_state clear > /dev/null
7373grep -Fq -- ' tab-action --surface surface-id --action rename --title surface' " $calls_file "
7474
7575: > " $calls_file "
76- MOCK_WORKSPACE_TITLE=" workspace${idle_marker } " run_state clear > /dev/null
76+ MOCK_WORKSPACE_TITLE=" workspace${stopped_marker } " run_state clear > /dev/null
7777grep -Fq -- ' workspace-action --workspace workspace-id --action rename --title workspace' " $calls_file "
7878if grep -Fq ' tab-action' " $calls_file " ; then
7979 printf ' marker-free surface was unexpectedly renamed during workspace migration\n' >&2
8282
8383: > " $calls_file "
8484run_state stopped > /dev/null
85- grep -Fq -- " tab-action --surface surface-id --action rename --title surface${idle_marker } " " $calls_file "
85+ grep -Fq -- " tab-action --surface surface-id --action rename --title surface${stopped_marker } " " $calls_file "
8686
8787: > " $calls_file "
88- run_state idle > /dev/null
89- grep -Fq -- " tab-action --surface surface-id --action rename --title surface${idle_marker} " " $calls_file "
88+ MOCK_SURFACE_TITLE= " surface ${working_marker} " run_state idle > /dev/null
89+ grep -Fq -- " tab-action --surface surface-id --action rename --title surface" " $calls_file "
9090
9191shell_home=" $test_dir /home"
9292shell_calls=" $test_dir /shell-calls"
@@ -165,7 +165,7 @@ jq -e '
165165 end))
166166' <<< " $rendered_codex_hooks" > /dev/null
167167
168- grep -Fq " if title.hasSuffix(\" ${idle_marker } \" ) { return \" idle \" }" " $SIDEBAR "
168+ grep -Fq " if title.hasSuffix(\" ${stopped_marker } \" ) { return \" stopped \" }" " $SIDEBAR "
169169python3 - " $SIDEBAR " << 'PY '
170170import pathlib
171171import sys
@@ -175,7 +175,9 @@ agent_state = source.split("func agentState", 1)[1].split("func stateTint", 1)[0
175175tab_state = source.split("func tabState", 1)[1].split("func workspaceRow", 1)[0]
176176assert agent_state.rstrip().endswith('return "idle"\n}')
177177assert "workspace.tabs.contains" in agent_state
178+ assert 'managedTitleState($0.title) == "stopped"' in agent_state
178179assert "managedTitleState(tab.title)" in tab_state
180+ assert 'if state == "stopped" { return "#FF9F0A" }' in source
179181assert "workspaceStatusText" not in source
180182assert "workspaceMemoText" not in source
181183assert "cmux-workspace-note" not in source
0 commit comments