Download tests/test_data.py from smlflg/meine-linux-app: direct link, hf CLI and curl.
- Browser
- Download file 641 Bytes
-
https://huggingface.co/smlflg/meine-linux-app/resolve/main/tests/test_data.py
- Command line
-
hf download hf://smlflg/meine-linux-app/tests/test_data.py
-
curl -L -o test_data.py https://huggingface.co/smlflg/meine-linux-app/resolve/main/tests/test_data.py
641 Bytes
| from pathlib import Path | |
| from meine_app.data import build_snapshot | |
| from meine_app.package import InputPackageDraft, freitext_sections | |
| def test_build_snapshot_counts_packages(tmp_path: Path): | |
| manifest_dir = tmp_path / "pkg-test" | |
| manifest_dir.mkdir() | |
| (manifest_dir / "manifest.json").write_text( | |
| '{"id":"pkg-test","name":"Test","created":"2026-01-01"}', | |
| encoding="utf-8", | |
| ) | |
| draft = InputPackageDraft(name="Neu", text_sections=freitext_sections("hello")) | |
| snapshot = build_snapshot(draft, tmp_path) | |
| assert snapshot.package_count == 1 | |
| assert snapshot.draft.text_sections[0].content == "hello" | |