[
  {
    "actions": [
      {
        "action": "navigate",
        "type": "navigate",
        "url": "{base_url}/"
      },
      {
        "action": "wait_for",
        "selector": "a[href=\"/projects\"]",
        "timeout_ms": 30000,
        "type": "wait_for_selector"
      },
      {
        "action": "click",
        "selector": "a[href=\"/projects\"]",
        "type": "click"
      },
      {
        "action": "wait_for",
        "selector": "input[placeholder=\"Search projects...\"]",
        "timeout_ms": 30000,
        "type": "wait_for_selector"
      },
      {
        "action": "click",
        "selector": "[data-testid=\"projects-th-customer\"]",
        "type": "click"
      },
      {
        "action": "wait_for",
        "selector": "table thead th:nth-child(3):has-text(\"Customer\")",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "table thead th:nth-child(4):has-text(\"Description\")",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-th-customer\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-th-description\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-kpi-active-invoiced-value\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-kpi-outstanding-balance-value\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "text": "Customer",
        "type": "assert_text"
      },
      {
        "text": "Description",
        "type": "assert_text"
      },
      {
        "text": "Active Invoiced",
        "type": "assert_text"
      },
      {
        "text": "Outstanding Balance",
        "type": "assert_text"
      },
      {
        "text": "Projects",
        "type": "assert_text"
      }
    ],
    "capture_each_step": true,
    "expected_result": "From the authenticated dashboard root, the user clicks the Projects sidebar link and lands on /projects. Column 3 is now \"Customer\" (was \"Task/Description\" pre-fix), column 4 is now \"Description\" (was \"Customer\" pre-fix). The Description cell shows only the description field (\"drop the task\" requirement). KPI cards (Active Invoiced = total_should_be_received + this_months_turnover; Outstanding Balance = total_should_be_received) now use the /api/invoices/stats endpoint that the Financials page uses, instead of the wildly inflated /api/invoices/stats/dashboard endpoint. All data-testids (projects-th-customer, projects-th-description, projects-kpi-active-invoiced-value, projects-kpi-outstanding-balance-value) were added in this fix and do not exist on pre-fix code, so every wait_for times out and FAILs on pre-fix code.",
    "human_journey": true,
    "name": "projects-bugfix-kpi-and-columns-journey-2026-06-15",
    "path": "/projects",
    "selectors": [],
    "source": "proof_contract",
    "start_path": "/",
    "texts": [
      "Projects"
    ]
  },
  {
    "actions": [
      {
        "action": "navigate",
        "type": "navigate",
        "url": "{base_url}/projects"
      },
      {
        "action": "wait_for",
        "selector": "input[placeholder=\"Search projects...\"]",
        "timeout_ms": 30000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "table thead th:nth-child(3):has-text(\"Customer\")",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "table thead th:nth-child(4):has-text(\"Description\")",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-th-customer\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-th-description\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-kpi-active-invoiced-value\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "action": "wait_for",
        "selector": "[data-testid=\"projects-kpi-outstanding-balance-value\"]",
        "timeout_ms": 15000,
        "type": "wait_for_selector"
      },
      {
        "text": "Customer",
        "type": "assert_text"
      },
      {
        "text": "Description",
        "type": "assert_text"
      },
      {
        "text": "Active Invoiced",
        "type": "assert_text"
      },
      {
        "text": "Outstanding Balance",
        "type": "assert_text"
      },
      {
        "text": "Projects",
        "type": "assert_text"
      }
    ],
    "capture_each_step": true,
    "expected_result": "Static render of the post-fix /projects page. Column 3 is Customer, column 4 is Description. KPI cards use /api/invoices/stats. All testids are new in this fix.",
    "human_journey": false,
    "kind": "static_render",
    "name": "projects-bugfix-kpi-and-columns-render-2026-06-15",
    "path": "/projects",
    "selectors": [],
    "source": "proof_contract",
    "start_path": "/projects",
    "texts": [
      "Projects"
    ]
  }
]