Download tests/test_markdown_sources.py from smlflg/AIOS-Cockpit: direct link, hf CLI and curl.
- Browser
- Download file 1.06 kB
-
https://huggingface.co/smlflg/AIOS-Cockpit/resolve/main/tests/test_markdown_sources.py
- Command line
-
hf download hf://smlflg/AIOS-Cockpit/tests/test_markdown_sources.py
-
curl -L -o test_markdown_sources.py https://huggingface.co/smlflg/AIOS-Cockpit/resolve/main/tests/test_markdown_sources.py
1.06 kB
| from pathlib import Path | |
| from aios_cockpit.markdown_sources import load_today_state | |
| def test_load_today_state_parses_active_table(tmp_path: Path) -> None: | |
| root = tmp_path | |
| (root / "ACTIVE.md").write_text( | |
| """# ACTIVE | |
| | # | Thema | Typ | Status | Naechster kleiner Schritt | | |
| |---|---|---|---|---| | |
| | 1 | Cockpit bauen | system | active | Snapshot starten | | |
| ## Tagesfokus | |
| - Cockpit MVP stabilisieren | |
| """, | |
| encoding="utf-8", | |
| ) | |
| (root / "INBOX.md").write_text( | |
| """# INBOX | |
| ## Eingegangen | |
| - Idee A | |
| - Idee B | |
| """, | |
| encoding="utf-8", | |
| ) | |
| (root / "DECISIONS.md").write_text( | |
| """# DECISIONS | |
| - **MVP vor Perfektion:** Erst nutzbar machen. | |
| """, | |
| encoding="utf-8", | |
| ) | |
| state = load_today_state(root) | |
| assert state.daily_focus == "Cockpit MVP stabilisieren" | |
| assert state.active_items[0].title == "Cockpit bauen" | |
| assert state.active_items[0].next_action == "Snapshot starten" | |
| assert state.inbox_items == ["Idee A", "Idee B"] | |
| assert "MVP vor Perfektion" in state.decisions[0] | |