mirror of
https://github.com/rennf93/roboco.git
synced 2026-08-03 07:23:24 +02:00
fix(.gitignore): anchor Python build artifacts; recover panel/src/lib (28 files)
The 'lib/' rule (intended for Python virtualenv at repo root) was matching panel/src/lib/, hiding the entire panel API client + utility tree from git. Anchored Python build-artifact rules to the repo root with a leading slash so they only match at the top level. Adds 28 panel/src/lib files that should have been tracked from day one.
This commit is contained in:
@@ -22,17 +22,17 @@ def _make_ctx() -> CommitContext:
|
||||
def test_build_commit_message_uses_given_api_base() -> None:
|
||||
"""build_commit_message embeds the api_base it receives."""
|
||||
ctx = _make_ctx()
|
||||
out = build_commit_message(ctx, "https://roboco.example.com/api/v1")
|
||||
assert "https://roboco.example.com/api/v1" in out
|
||||
out = build_commit_message(ctx, "https://roboco.example.com/api")
|
||||
assert "https://roboco.example.com/api" in out
|
||||
assert "127.0.0.1" not in out
|
||||
|
||||
|
||||
def test_build_commit_message_strips_trailing_slash() -> None:
|
||||
"""Trailing slash on api_base is stripped to avoid double slashes."""
|
||||
ctx = _make_ctx()
|
||||
out = build_commit_message(ctx, "https://roboco.example.com/api/v1/")
|
||||
out = build_commit_message(ctx, "https://roboco.example.com/api/")
|
||||
assert "//tasks/" not in out
|
||||
assert "https://roboco.example.com/api/v1/tasks/" in out
|
||||
assert "https://roboco.example.com/api/tasks/" in out
|
||||
|
||||
|
||||
def test_links_use_public_base_url(monkeypatch: pytest.MonkeyPatch) -> None:
|
||||
@@ -41,7 +41,7 @@ def test_links_use_public_base_url(monkeypatch: pytest.MonkeyPatch) -> None:
|
||||
importlib.reload(config_module)
|
||||
try:
|
||||
settings = config_module.Settings()
|
||||
api_base = settings.public_base_url.rstrip("/") + "/api/v1"
|
||||
api_base = settings.public_base_url.rstrip("/") + "/api"
|
||||
ctx = _make_ctx()
|
||||
out = build_commit_message(ctx, api_base)
|
||||
assert "https://roboco.example.com" in out
|
||||
|
||||
Reference in New Issue
Block a user