Target the tmux session as =<session>: for its @loop-root option, which set-option and show-options read as a pane's target
CI / tests (pull_request) Successful in 2m57s
CI / tests (pull_request) Successful in 2m57s
This commit is contained in:
@@ -1295,7 +1295,7 @@ class TmuxCommands(unittest.TestCase):
|
||||
self.assertIsNone(tmux.start_window(window, "/r", {}, ["/b/loop-claude"], False, fake.tmux))
|
||||
self.assertEqual(fake.tmux_calls, [
|
||||
["new-session", "-d", "-s", "loop-proj", "-n", "item-7", "-c", "/r", "-e", "LOOP_CLAUDE_X=1", "-P", "-F", "#{window_id}", "--", "/b/loop-claude", "--chunk", "item-7", "ship it\;"],
|
||||
["set-option", "-t", "=loop-proj", "@loop-root", "/r"],
|
||||
["set-option", "-t", "=loop-proj:", "@loop-root", "/r"],
|
||||
["set-option", "-w", "-t", "@9", "remain-on-exit", "failed"],
|
||||
["new-window", "-d", "-t", "=loop-proj:", "-n", "item-7", "-c", "/r", "-P", "-F", "#{window_id}", "--", "/b/loop-claude"],
|
||||
["set-option", "-w", "-t", "@9", "remain-on-exit", "failed"],
|
||||
@@ -1311,7 +1311,7 @@ class TmuxCommands(unittest.TestCase):
|
||||
def test_reads_the_checkout_the_session_names(self):
|
||||
fake = FakeEffects(owner="/c/proj")
|
||||
self.assertEqual(tmux.owner("loop-proj", fake.tmux), "/c/proj")
|
||||
self.assertEqual(fake.tmux_calls, [["show-options", "-qv", "-t", "=loop-proj", "@loop-root"]])
|
||||
self.assertEqual(fake.tmux_calls, [["show-options", "-qv", "-t", "=loop-proj:", "@loop-root"]])
|
||||
|
||||
def test_marks_a_waiting_window_by_its_pane_and_clears_the_mark(self):
|
||||
fake = FakeEffects()
|
||||
@@ -1440,7 +1440,7 @@ class StartChunks(unittest.TestCase):
|
||||
self.assertEqual([word for word in first if "=" in word], ["LOOP_CLAUDE_WORKER_MODEL=m"])
|
||||
self.assertEqual(fake.tmux_calls[0], ["list-windows", "-t", f"={self.session}", "-F", "#{window_name}\t#{pane_dead}\t#{window_id}"])
|
||||
# The session names the checkout whose chunks it runs.
|
||||
self.assertIn(["set-option", "-t", f"={self.session}", "@loop-root", str(self.root)], fake.tmux_calls)
|
||||
self.assertIn(["set-option", "-t", f"={self.session}:", "@loop-root", str(self.root)], fake.tmux_calls)
|
||||
|
||||
def test_refuses_a_session_that_runs_another_checkouts_chunks(self):
|
||||
for owner, named in (("/c/acme.api", "/c/acme.api"), ("", "another checkout")):
|
||||
|
||||
Reference in New Issue
Block a user