============================= test session starts ============================== platform linux -- Python 3.10.12, pytest-9.0.1, pluggy-1.6.0 -- /usr/bin/python3 cachedir: .pytest_cache metadata: {'Python': '3.10.12', 'Platform': 'Linux-6.8.0-1041-azure-x86_64-with-glibc2.35', 'Packages': {'pytest': '9.0.1', 'pluggy': '1.6.0'}, 'Plugins': {'env': '1.2.0', 'anyio': '3.7.1', 'html': '4.1.1', 'cov': '4.1.0', 'asyncio': '1.3.0', 'mock': '3.15.1', 'metadata': '3.1.1', 'Faker': '38.2.0', 'xdist': '3.8.0'}} rootdir: /mnt/data-disk1/archie-platform-v3-worktrees/authentication-service-implementation configfile: pytest.ini (WARNING: ignoring pytest config in pyproject.toml!) plugins: env-1.2.0, anyio-3.7.1, html-4.1.1, cov-4.1.0, asyncio-1.3.0, mock-3.15.1, metadata-3.1.1, Faker-38.2.0, xdist-3.8.0 asyncio: mode=auto, debug=False, asyncio_default_fixture_loop_scope=None, asyncio_default_test_loop_scope=function collecting ... collected 12 items tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_successful_login_flow -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:56 [ INFO] Login successful: email=alice@acme.com, state=q21JoP-t... 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 200 OK" PASSED [ 8%] tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_rate_limiting_behavior -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:56 [ WARNING] Rate limit exceeded: ip=127.0.0.1 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 429 Too Many Requests" PASSED [ 16%] tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_blocked_domain_rejection -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=attacker@tempmail.com, ip=127.0.0.1 2025-12-03 16:18:56 [ WARNING] Login rejected: email=attacker@tempmail.com, reason=blocked_domain 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 403 Forbidden" PASSED [ 25%] tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_invalid_redirect_uri -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:56 [ WARNING] Invalid redirect_uri: https://malicious.com/callback 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 400 Bad Request" PASSED [ 33%] tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_workos_timeout_handling -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:56 [ ERROR] WorkOS timeout: WorkOS timeout 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 503 Service Unavailable" PASSED [ 41%] tests/integration/test_workos_login_simple.py::TestWorkOSLoginEndpoint::test_email_normalization -------------------------------- live log call --------------------------------- 2025-12-03 16:18:56 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:56 [ INFO] Login successful: email=alice@acme.com, state=FfAxXjiK... 2025-12-03 16:18:56 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 200 OK" PASSED [ 50%] tests/integration/test_workos_login_simple.py::TestServiceContracts::test_workos_client_contract PASSED [ 58%] tests/integration/test_workos_login_simple.py::TestServiceContracts::test_workos_client_timeout_behavior PASSED [ 66%] tests/integration/test_workos_login_simple.py::TestMockCoordination::test_state_parameter_lifecycle PASSED [ 75%] tests/integration/test_workos_login_simple.py::TestMockCoordination::test_rate_limit_coordination PASSED [ 83%] tests/integration/test_workos_login_simple.py::TestBehaviorVerification::test_login_workflow_sequence -------------------------------- live log call --------------------------------- 2025-12-03 16:18:57 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:57 [ INFO] Login successful: email=alice@acme.com, state=toNohWeV... 2025-12-03 16:18:57 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 200 OK" PASSED [ 91%] tests/integration/test_workos_login_simple.py::TestBehaviorVerification::test_error_handling_workflow -------------------------------- live log call --------------------------------- 2025-12-03 16:18:57 [ INFO] Login attempt: email=alice@acme.com, ip=127.0.0.1 2025-12-03 16:18:57 [ WARNING] Rate limit exceeded: ip=127.0.0.1 2025-12-03 16:18:57 [ INFO] HTTP Request: POST http://testserver/api/auth/login "HTTP/1.1 429 Too Many Requests" PASSED [100%] ============================== 12 passed in 1.10s ==============================