🌐 Add Portuguese translation for `docs/pt/docs/advanced/testing-websockets.md` (#11994)

This commit is contained in:
Rafael de Oliveira Marques 2024-08-15 17:36:31 +02:00 committed by GitHub
parent 4fe1af494a
commit 60fe2b19e8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,15 @@
# Testando WebSockets
Você pode usar o mesmo `TestClient` para testar WebSockets.
Para isso, você utiliza o `TestClient` dentro de uma instrução `with`, conectando com o WebSocket:
```Python hl_lines="27-31"
{!../../../docs_src/app_testing/tutorial002.py!}
```
/// note | "Nota"
Para mais detalhes, confira a documentação do Starlette para <a href="https://www.starlette.io/testclient/#testing-websocket-sessions" class="external-link" target="_blank">testar WebSockets</a>.
///