Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for AsyncClient (0.57 sec)

  1. docs_src/async_tests/test_main.py

    import pytest
    from httpx import ASGITransport, AsyncClient
    
    from .main import app
    
    
    @pytest.mark.anyio
    async def test_root():
        async with AsyncClient(
            transport=ASGITransport(app=app), base_url="http://test"
        ) as ac:
            response = await ac.get("/")
        assert response.status_code == 200
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Aug 30 16:00:41 UTC 2024
    - 360 bytes
    - Viewed (0)
  2. docs/pt/docs/advanced/async-tests.md

    /// tip | "Dica"
    
    Note que nós estamos utilizando async/await com o novo `AsyncClient` - a requisição é assíncrona.
    
    ///
    
    /// warning | "Aviso"
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  3. docs/de/docs/advanced/async-tests.md

    /// tip | "Tipp"
    
    Beachten Sie, dass wir async/await mit dem neuen `AsyncClient` verwenden – der Request ist asynchron.
    
    ///
    
    /// warning | "Achtung"
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 15:34:47 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  4. docs/en/docs/advanced/async-tests.md

    ///
    
    Then we can create an `AsyncClient` with the app, and send async requests to it, using `await`.
    
    {* ../../docs_src/async_tests/test_main.py hl[9:12] *}
    
    This is the equivalent to:
    
    ```Python
    response = client.get('/')
    ```
    
    ...that we used to make our requests with the `TestClient`.
    
    /// tip
    
    Note that we're using async/await with the new `AsyncClient` - the request is asynchronous.
    
    ///
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 15:43:29 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  5. docs/em/docs/advanced/async-tests.md

    ///
    
    ⤴️ 👥 💪 ✍ `AsyncClient` ⏮️ 📱, & 📨 🔁 📨 ⚫️, ⚙️ `await`.
    
    ```Python hl_lines="9-12"
    {!../../docs_src/async_tests/test_main.py!}
    ```
    
    👉 🌓:
    
    ```Python
    response = client.get('/')
    ```
    
    ...👈 👥 ⚙️ ⚒ 👆 📨 ⏮️ `TestClient`.
    
    /// tip
    
    🗒 👈 👥 ⚙️ 🔁/⌛ ⏮️ 🆕 `AsyncClient` - 📨 🔁.
    
    ///
    
    ## 🎏 🔁 🔢 🤙
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 3K bytes
    - Viewed (0)
  6. docs/en/docs/release-notes.md

    * 📝 Add warning about lifecycle events with `AsyncClient`. PR [#4167](https://github.com/tiangolo/fastapi/pull/4167) by [@andrew-chang-dewitt](https://github.com/andrew-chang-dewitt).
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Nov 01 11:25:57 UTC 2024
    - 460.3K bytes
    - Viewed (0)
Back to top