import pytest from django.conf import settings from django.core.cache import cache from django.test import override_settings from django.urls import reverse from django.utils import timezone from apps.jobs.models import JobPosting, ScoreRun @pytest.mark.integration @pytest.mark.django_db def test_today_requires_login(client): response = client.get(reverse("dashboard:today")) assert response.status_code == 302 assert reverse("login") in response.url @pytest.mark.integration @pytest.mark.django_db def test_browser_favicon_and_product_brand_assets_are_local(client): response = client.get("/favicon.ico") assert response.status_code == 301 assert response.url.endswith("/static/favicon.svg") favicon = (settings.BASE_DIR / "static" / "favicon.svg").read_text(encoding="utf-8") product_logo = (settings.BASE_DIR / "static" / "img" / "vacatureradar-logo.svg").read_text( encoding="utf-8" ) wordmark = settings.BASE_DIR / "static" / "img" / "itworx-wordmark.png" for signature in ('stroke="#19d3e6"', 'stroke="#7df5ff"', 'fill="#45d69b"'): assert signature in favicon assert 'stroke="#19d3e6"' in product_logo assert 'fill="#36c990"' in product_logo assert "