"""Tests for app/views/integrations.py — the unified integrations dashboard. Covers the /integrations view route, quota rendering, and unit-level helpers for subscription-tier limits. """ from unittest.mock import MagicMock, patch import pytest # --------------------------------------------------------------------------- # Integration tests — real HTTP round-trips via the TestClient # --------------------------------------------------------------------------- @pytest.mark.integration class TestIntegrationsDashboardView: """Integration tests for the GET /integrations view route.""" def test_integrations_page_returns_200(self, client): """GET /integrations returns HTTP 200.""" response = client.get("/integrations") assert response.status_code == 200 def test_integrations_page_renders_html(self, client): """GET /integrations returns HTML content with a proper html tag.""" response = client.get("/integrations") assert response.status_code == 200 assert b"