feat(translate): refonte du design de la page de traduction et du sélecteur de moteurs (Etapes 1-3)
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 2m12s
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 2m12s
This commit is contained in:
@@ -891,3 +891,23 @@ class TestAPIKeyAuth:
|
||||
headers={"X-API-Key": "test-api-key-placeholder"},
|
||||
)
|
||||
assert response.status_code in [202, 401]
|
||||
|
||||
|
||||
class TestTranslateImagesParameter:
|
||||
"""Test translate_images parameter in POST /api/v1/translate"""
|
||||
|
||||
def test_accepts_translate_images_parameter(self, authenticated_client):
|
||||
"""Endpoint accepts translate_images form parameter"""
|
||||
excel_content = create_valid_excel()
|
||||
response = authenticated_client.post(
|
||||
TRANSLATE_URL,
|
||||
files={
|
||||
"file": (
|
||||
"test.xlsx",
|
||||
io.BytesIO(excel_content),
|
||||
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
||||
)
|
||||
},
|
||||
data={"target_lang": "fr", "translate_images": "true"},
|
||||
)
|
||||
assert response.status_code == 202
|
||||
|
||||
Reference in New Issue
Block a user