Deploy durable tenant authority runtime

This commit is contained in:
tegwick 2026-08-09 01:35:00 +02:00
parent 8bd0741104
commit 1e44cace1f
6 changed files with 210 additions and 2 deletions

View file

@ -0,0 +1,11 @@
from tenant_engine.domain import Tenant
from tenant_engine.sqlite_store import SQLiteTenantStore
def test_tenant_survives_store_reopen(tmp_path):
path = str(tmp_path / "tenants.db")
SQLiteTenantStore(path).create_tenant(
Tenant.create(tenant_id="tenant:friendly:new", identifier="tenant:friendly:new")
)
tenant = SQLiteTenantStore(path).get_tenant("tenant:friendly:new")
assert tenant.grouping == "friendly"