Initial SyncVito release with installer updater

This commit is contained in:
Davito committed 2026-09-23 19:40:36 +02:00
commit b9e4c09f49
41 files changed
+4331

No files matched your search

+30
View File
@@ -0,0 +1,30 @@
from pathlib import Path
from syncvito.config_store import ConfigStore
from syncvito.models import AppConfig, AppSettings, SyncDirection, SyncTask
def test_config_roundtrip(tmp_path: Path) -> None:
path = tmp_path / "config.json"
config = AppConfig(
tasks=[
SyncTask(
name="Archiv",
source=str(tmp_path / "quelle"),
target=str(tmp_path / "ziel"),
direction=SyncDirection.BIDIRECTIONAL,
selected_paths=["Dokumente"],
)
],
settings=AppSettings(font_size=12, ui_scale=110, check_updates_on_start=False),
)
ConfigStore(path).save(config)
loaded = ConfigStore(path).load()
assert loaded.settings.font_size == 12
assert loaded.settings.ui_scale == 110
assert loaded.settings.check_updates_on_start is False
assert loaded.tasks[0].name == "Archiv"
assert loaded.tasks[0].direction is SyncDirection.BIDIRECTIONAL
assert loaded.tasks[0].selected_paths == ["Dokumente"]