- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 78 for 401 (0.02 sec)
-
tests/test_security_http_basic_realm.py
assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == 'Basic realm="simple"' def test_security_http_basic_invalid_credentials(): response = client.get( "/users/me", headers={"Authorization": "Basic notabase64token"} ) assert response.status_code == 401, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.6K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial006_an_py39.py
assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == "Basic" @needs_py39 def test_security_http_basic_invalid_credentials(client: TestClient): response = client.get( "/users/me", headers={"Authorization": "Basic notabase64token"} ) assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == "Basic"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.5K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial003.py
assert response.status_code == 401, response.text assert response.json() == {"detail": "Invalid authentication credentials"} assert response.headers["WWW-Authenticate"] == "Bearer" def test_incorrect_token_type(): response = client.get( "/users/me", headers={"Authorization": "Notexistent testtoken"} ) assert response.status_code == 401, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 8K bytes - Viewed (0) -
tests/test_security_http_basic_realm_description.py
assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == 'Basic realm="simple"' def test_security_http_basic_invalid_credentials(): response = client.get( "/users/me", headers={"Authorization": "Basic notabase64token"} ) assert response.status_code == 401, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/authenticator/JavaNetAuthenticatorTest.kt
val request = Request.Builder() .url("https://server/robots.txt") .build() val response = Response.Builder() .request(request) .code(401) .header("WWW-Authenticate", "Basic realm=\"User Visible Realm\"") .protocol(HTTP_2) .message("Unauthorized") .build() val authRequest = authenticator.authenticate(route, response)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.7K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial003_an_py39.py
assert response.json() == {"detail": "Incorrect username or password"} @needs_py39 def test_no_token(client: TestClient): response = client.get("/users/me") assert response.status_code == 401, response.text assert response.json() == {"detail": "Not authenticated"} assert response.headers["WWW-Authenticate"] == "Bearer" @needs_py39 def test_token(client: TestClient):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 8.4K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial001_an_py39.py
client = TestClient(app) return client @needs_py39 def test_no_token(client: TestClient): response = client.get("/items") assert response.status_code == 401, response.text assert response.json() == {"detail": "Not authenticated"} assert response.headers["WWW-Authenticate"] == "Bearer" @needs_py39 def test_token(client: TestClient):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.1K bytes - Viewed (0) -
tests/test_tutorial/test_security/test_tutorial001.py
from fastapi.testclient import TestClient from docs_src.security.tutorial001 import app client = TestClient(app) def test_no_token(): response = client.get("/items") assert response.status_code == 401, response.text assert response.json() == {"detail": "Not authenticated"} assert response.headers["WWW-Authenticate"] == "Bearer" def test_token():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 1.9K bytes - Viewed (0) -
src/main/config/openapi/openapi-user.yaml
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu May 09 06:31:27 UTC 2024 - 21.6K bytes - Viewed (0) -
tests/test_security_http_basic_optional.py
def test_security_http_basic_invalid_credentials(): response = client.get( "/users/me", headers={"Authorization": "Basic notabase64token"} ) assert response.status_code == 401, response.text assert response.headers["WWW-Authenticate"] == "Basic" assert response.json() == {"detail": "Invalid authentication credentials"} def test_security_http_basic_non_basic_credentials():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.6K bytes - Viewed (0)