- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for test_security_http_basic_non_basic_credentials (0.27 sec)
-
tests/test_tutorial/test_security/test_tutorial007.py
) assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == "Basic" assert response.json() == {"detail": "Not authenticated"} def test_security_http_basic_non_basic_credentials(client: TestClient): payload = b64encode(b"johnsecret").decode("ascii") auth_header = f"Basic {payload}" response = client.get("/users/me", headers={"Authorization": auth_header})Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 3.2K bytes - Viewed (0)