Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 71 for fare (0.16 sec)

  1. tests/test_tutorial/test_dependencies/test_tutorial012.py

        response = client.get(
            "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
        assert response.status_code == 400, response.text
        assert response.json() == {"detail": "X-Key header invalid"}
    
    
    def test_get_invalid_second_header_users():
        response = client.get(
            "/users/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  2. tests/test_tutorial/test_dependencies/test_tutorial012_an.py

        response = client.get(
            "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
        assert response.status_code == 400, response.text
        assert response.json() == {"detail": "X-Key header invalid"}
    
    
    def test_get_invalid_second_header_users():
        response = client.get(
            "/users/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  3. tests/test_tutorial/test_dependencies/test_tutorial006.py

            "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
        assert response.status_code == 400, response.text
        assert response.json() == {"detail": "X-Key header invalid"}
    
    
    def test_get_valid_headers():
        response = client.get(
            "/items/",
            headers={
                "X-Token": "fake-super-secret-token",
                "X-Key": "fake-super-secret-key",
            },
        )
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 5K bytes
    - Viewed (0)
  4. tests/test_tutorial/test_dependencies/test_tutorial006_an.py

            "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
        assert response.status_code == 400, response.text
        assert response.json() == {"detail": "X-Key header invalid"}
    
    
    def test_get_valid_headers():
        response = client.get(
            "/items/",
            headers={
                "X-Token": "fake-super-secret-token",
                "X-Key": "fake-super-secret-key",
            },
        )
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 5K bytes
    - Viewed (0)
  5. tests/test_tutorial/test_bigger_applications/test_main_an.py

            "/items?token=jessica", headers={"X-Token": "fake-super-secret-token"}
        )
        assert response.status_code == 200
        assert response.json() == {
            "plumbus": {"name": "Plumbus"},
            "gun": {"name": "Portal Gun"},
        }
    
    
    def test_items_with_no_token_jessica(client: TestClient):
        response = client.get("/items", headers={"X-Token": "fake-super-secret-token"})
        assert response.status_code == 422
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 24.6K bytes
    - Viewed (0)
  6. tests/test_tutorial/test_bigger_applications/test_main_an_py39.py

            "/items?token=jessica", headers={"X-Token": "fake-super-secret-token"}
        )
        assert response.status_code == 200
        assert response.json() == {
            "plumbus": {"name": "Plumbus"},
            "gun": {"name": "Portal Gun"},
        }
    
    
    @needs_py39
    def test_items_with_no_token_jessica(client: TestClient):
        response = client.get("/items", headers={"X-Token": "fake-super-secret-token"})
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 24.9K bytes
    - Viewed (0)
  7. docs/en/docs/tutorial/dependencies/index.md

    ## Simple usage
    
    If you look at it, *path operation functions* are declared to be used whenever a *path* and *operation* matches, and then **FastAPI** takes care of calling the function with the correct parameters, extracting the data from the request.
    
    Actually, all (or most) of the web frameworks work in this same way.
    
    You never call those functions directly. They are called by your framework (in this case, **FastAPI**).
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_dependencies/test_tutorial012_an_py39.py

            "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
        assert response.status_code == 400, response.text
        assert response.json() == {"detail": "X-Key header invalid"}
    
    
    @needs_py39
    def test_get_invalid_second_header_users(client: TestClient):
        response = client.get(
            "/users/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"}
        )
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 8.8K bytes
    - Viewed (0)
  9. docs/en/docs/advanced/sub-applications.md

    ## Mounting a **FastAPI** application
    
    "Mounting" means adding a completely "independent" application in a specific path, that then takes care of handling everything under that path, with the _path operations_ declared in that sub-application.
    
    ### Top-level application
    
    First, create the main, top-level, **FastAPI** application, and its *path operations*:
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 2.9K bytes
    - Viewed (0)
  10. docs/en/docs/deployment/server-workers.md

    You could use these tools and ideas if you are setting up **your own deployment system** while taking care of the other deployment concepts yourself.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 9.1K bytes
    - Viewed (0)
Back to top