Automate RC8 release journeys
GeoIntel release gates / Compile, test, contracts and builds (push) Canceled after 0s
GeoIntel release gates / Python and npm vulnerability policy (push) Canceled after 0s
GeoIntel release gates / GIS image, SBOM and container scan (push) Canceled after 0s

This commit is contained in:
Codex
2026-07-18 06:07:44 +02:00
parent 0fae53a7de
commit 55685ba1bd
22 changed files with 2665 additions and 11 deletions
@@ -5,6 +5,7 @@ from uuid import uuid4
from fastapi.testclient import TestClient
from app.main import app
from app.models import Project
from app.schemas.demo import DemoWorkflowResponse
from app.services.demo_workflow_service import DemoWorkflowService
@@ -80,3 +81,30 @@ def test_demo_workflow_prefers_complete_existing_demo_project() -> None:
assert "order_by(Project.created_at.asc())" in service
assert "if DemoWorkflowService._has_complete_demo_state(db, project.id):" in service
assert "return projects[0] if projects else None" in service
def test_explicit_demo_seed_reactivates_an_archived_fixture_project() -> None:
project = Project(id=uuid4(), name=DemoWorkflowService.PROJECT_NAME, status="archived")
class Session:
added = []
commits = 0
refreshed = []
def add(self, value) -> None:
self.added.append(value)
def commit(self) -> None:
self.commits += 1
def refresh(self, value) -> None:
self.refreshed.append(value)
db = Session()
result = DemoWorkflowService._activate_explicit_demo_project(db, project)
assert result is project
assert project.status == "active"
assert db.added == [project]
assert db.commits == 1
assert db.refreshed == [project]