chore(repo): initialize Cowork Local Gitea repository
CI / test (push) Canceled after 0s

This commit is contained in:
thanhnv
2026-08-09 20:12:05 +07:00
commit 414eaddca3
192 changed files with 48160 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
from __future__ import annotations
from cowork_local.config import AppConfig, DEFAULT_CONFIG
def test_unlock_codes_have_no_shared_default() -> None:
assert DEFAULT_CONFIG["agent_security"]["sandbox_pw"] == ""
assert DEFAULT_CONFIG["ms365"]["unlock_code"] == ""
def test_unlock_codes_can_be_supplied_by_environment(tmp_path, monkeypatch) -> None:
monkeypatch.setenv("COWORK_SANDBOX_PASSWORD", "sandbox-test-only")
monkeypatch.setenv("COWORK_MS365_UNLOCK_CODE", "ms365-test-only")
config = AppConfig.load(tmp_path / "missing.json")
assert config.agent_security["sandbox_pw"] == "sandbox-test-only"
assert config.ms365["unlock_code"] == "ms365-test-only"