Initial commit

This commit is contained in:
Warezpeddler
2026-04-25 23:09:31 +01:00
commit 3325436017
92 changed files with 18397 additions and 0 deletions

24
tests/test_deck_export.py Normal file
View File

@@ -0,0 +1,24 @@
"""Presentation exportaligned checks (reference path and portable pieces)."""
from pathlib import Path
import pytest
from applepy.checks.deck_export import check_deck_export_reference, check_kube_config_presence
from applepy.context import RunContext
def test_deck_reference_finds_export(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:
monkeypatch.chdir(tmp_path)
name = "APPLEPY_DECK_REFERENCE.txt"
(tmp_path / name).write_text("stub export\n", encoding="utf-8")
ctx = RunContext(home=tmp_path, output_dir=tmp_path, phase="unprivileged")
out = check_deck_export_reference(ctx)
assert len(out) == 1
assert out[0].id == "deck-000"
assert "located" in out[0].title.lower()
def test_kube_config_absent(tmp_path: Path) -> None:
ctx = RunContext(home=tmp_path, output_dir=tmp_path, phase="unprivileged")
out = check_kube_config_presence(ctx)
assert out[0].id == "deck-104"