SignalMesh / tests /test_migration_builder_runtime.py
k0880k
test(migration): assert explicit participant inventory
a31ad8a
Raw History Blame Contribute Delete
1.19 kB
from pathlib import Path
def test_builder_installs_migration_explicitly():
text = Path('editor/__init__.py').read_text()
assert 'migration_routes.install(module.app)' in text
def test_core_bootstrap_does_not_install_migration_ui():
text = Path('core/__init__.py').read_text()
assert '_safe("migration_lifecycle_suite"' not in text
assert '_safe("migration_scope_suite"' not in text
def test_migration_inventory_excludes_ambient_default_site():
text = Path('editor/migration_inventory.py').read_text()
assert 'def sites()' in text
assert 'mesh._SESSION_SITES' in text or 'getattr(mesh, "_SESSION_SITES"' in text
assert 'mesh.registry_path()' in text
assert '_env_from_process' not in text
assert '_parse_env' not in text
def test_workspace_uses_migration_specific_inventory():
text = Path('editor/migration_routes.py').read_text()
assert '"./api/sites/names", "./api/migration/sites"' in text
assert '"/api/migration/sites"' in text
def test_preview_catch_all_is_forced_last():
text = Path('editor/migration_routes.py').read_text()
assert '"/{path:path}"' in text
assert '_move_preview_catch_all_last(app)' in text