feat(platform): close AI expense value loop
Add tenant-safe value, telemetry, connector, commercial, and production-readiness foundations.
This commit is contained in:
@@ -51,8 +51,12 @@ def build_client() -> TestClient:
|
||||
def test_notification_state_service_persists_user_scoped_read_and_hidden_state() -> None:
|
||||
with build_session() as db:
|
||||
service = NotificationStateService(db)
|
||||
user = CurrentUserContext(username="alice", name="Alice", role_codes=[], is_admin=False)
|
||||
other_user = CurrentUserContext(username="bob", name="Bob", role_codes=[], is_admin=False)
|
||||
user = CurrentUserContext(
|
||||
tenant_id="default", username="alice", name="Alice", role_codes=[], is_admin=False
|
||||
)
|
||||
other_user = CurrentUserContext(
|
||||
tenant_id="default", username="bob", name="Bob", role_codes=[], is_admin=False
|
||||
)
|
||||
|
||||
saved = service.patch_states(
|
||||
NotificationStateBatchPatch(
|
||||
@@ -90,7 +94,9 @@ def test_notification_state_service_persists_user_scoped_read_and_hidden_state()
|
||||
def test_notification_state_storage_ready_runs_once_per_database_bind(monkeypatch) -> None:
|
||||
with build_session() as db:
|
||||
service = NotificationStateService(db)
|
||||
user = CurrentUserContext(username="alice", name="Alice", role_codes=[], is_admin=False)
|
||||
user = CurrentUserContext(
|
||||
tenant_id="default", username="alice", name="Alice", role_codes=[], is_admin=False
|
||||
)
|
||||
calls: list[object] = []
|
||||
original_create_all = Base.metadata.create_all
|
||||
|
||||
|
||||
Reference in New Issue
Block a user