Skip to content

Commit

Permalink
Corriger un test sur main
Browse files Browse the repository at this point in the history
  • Loading branch information
Anto59290 authored and alanzirek committed Feb 20, 2025
1 parent c938355 commit 9f06b82
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions sv/tests/test_evenement_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,9 +625,8 @@ def test_can_delete_document_attached_to_message(live_server, page: Page, mocked
assert document.deleted_by == mocked_authentification_user.agent


def test_message_with_document_exceeding_max_size_shows_validation_error(
live_server, page: Page, with_active_contact, choice_js_fill
):
def test_message_with_document_exceeding_max_size_shows_validation_error(live_server, page: Page, choice_js_fill):
active_contact = ContactAgentFactory(with_active_agent=True).agent
# Créer un fichier temporaire CSV de 16Mo
file_size = 16 * 1024 * 1024
fd, temp_path = tempfile.mkstemp(suffix=".csv")
Expand All @@ -641,8 +640,8 @@ def test_message_with_document_exceeding_max_size_shows_validation_error(
choice_js_fill(
page,
".choices__input--cloned:first-of-type",
with_active_contact.nom,
with_active_contact.contact_set.get().display_with_agent_unit,
active_contact.nom,
active_contact.contact_set.get().display_with_agent_unit,
)
page.locator("#id_title").fill("Message avec fichier trop volumineux")
page.locator("#id_content").fill("Test de validation de taille de fichier")
Expand Down

0 comments on commit 9f06b82

Please sign in to comment.