diff options
| author | Christophe Besson <cbesson@gmail.com> | 2026-09-24 18:19:13 +0200 |
|---|---|---|
| committer | Christophe Besson <cbesson@gmail.com> | 2026-09-24 18:19:13 +0200 |
| commit | 6e9afe3e54ab6fb0162393150b7892655b4561d4 (patch) | |
| tree | f1cf20d891bf0d75dd206953bcec781f47ab7b15 /packages/meshbay-node/tests/test_roster_pairing.py | |
| parent | a408a25af7b91abf729ec5fac7e5506437a86049 (diff) | |
| download | meshbay-6e9afe3e54ab6fb0162393150b7892655b4561d4.tar.gz | |
refactor(node): move the CLI out of daemon.py into cli/
Each `if args.command == ...` branch of main() becomes a function in
cli/ (one module per family of verbs); the parser, the process setup
and a VERBS table go to cli/parser.py and cli/dispatch.py. daemon.main
runs the verb or starts the daemon. Tests patch the CLI through
conftest.patch_cli; the CLI golden is unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'packages/meshbay-node/tests/test_roster_pairing.py')
| -rw-r--r-- | packages/meshbay-node/tests/test_roster_pairing.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/meshbay-node/tests/test_roster_pairing.py b/packages/meshbay-node/tests/test_roster_pairing.py index ba16317..a2d0f8b 100644 --- a/packages/meshbay-node/tests/test_roster_pairing.py +++ b/packages/meshbay-node/tests/test_roster_pairing.py @@ -25,7 +25,7 @@ from meshbay_node.roster import Roster, hash_code, normalize_code from meshbay_node.transport.webrtc_server import WebRTCPeerSession from node_source import daemon_source, session_method, webrtc_source -from conftest import one_root +from conftest import one_root, patch_cli # ── Fixtures ────────────────────────────────────────────────────────────────── @@ -823,7 +823,7 @@ def _run_cli(monkeypatch, tmp_path, argv, responses): return value return {} - monkeypatch.setattr(_daemon, "_daemon_api", fake_api) + patch_cli(monkeypatch, "_daemon_api", fake_api) conf = tmp_path / "node.toml" tp = tmp_path.as_posix() # a raw Windows path is a TOML escape error |