Skip to content

Employeur: conserver les filtres de la page de candidature après une action sur une candidature#4712

Merged
tonial merged 1 commit intomasterfrom
alaurent/apply_filters
Sep 19, 2024
Merged

Employeur: conserver les filtres de la page de candidature après une action sur une candidature#4712
tonial merged 1 commit intomasterfrom
alaurent/apply_filters

Conversation

@tonial
Copy link
Contributor

@tonial tonial commented Sep 10, 2024

🤔 Pourquoi ?

🍰 Comment ?

Décrivez en quelques mots la solution retenue et mise en oeuvre, les difficultés ou problèmes rencontrés. Attirez l'attention sur les décisions d'architecture ou de conception importantes.

🚨 À vérifier

  • Mettre à jour le CHANGELOG_breaking_changes.md ?

🏝️ Comment tester

Les instructions pour reproduire le problème, les profils de test, le parcours spécifique à utiliser, etc. Si vous disposez d'une recette jetable, mettre l'URL pour tester dans cette partie.

💻 Captures d'écran

@tonial tonial added the modifié Modifié dans le changelog. label Sep 10, 2024
@tonial tonial self-assigned this Sep 10, 2024
@tonial tonial changed the title Employeur: conserver les filtres de la page de candidature après une action sur une candidature [GEN-212] Employeur: conserver les filtres de la page de candidature après une action sur une candidature Sep 10, 2024
job_application.resume_link = ""
job_application.save(update_fields=["resume_link"])
with freeze_time("2023-12-12 13:37:00") as initial_invite_time:
job_application = JobApplicationFactory(
Copy link
Contributor Author

@tonial tonial Sep 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

à cause de l'opération sur la session dans la vue details_for_company si on saute à une date trop éloignée, l'utilisateur est automatiquement déconnecté.
J'ai donc passé tout le test à une date fixe (en avançant un peu dans le temps à chaque post/get)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tu peux transformer le context manager en décorateur pour mieux l’indiquer et gagner un niveau d’indentation.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

L’explication du changement de ce test serait très utile en message de commit.

@tonial tonial force-pushed the alaurent/apply_filters branch 3 times, most recently from d191e31 to 0a3d5f4 Compare September 11, 2024 04:06
@tonial tonial added the 1-recette-jetable [Payé à l’heure] Crée une recette jetable sur CC label Sep 11, 2024
@github-actions
Copy link

🥁 La recette jetable est prête ! 👉 Je veux tester cette PR !

@tonial tonial force-pushed the alaurent/apply_filters branch 4 times, most recently from 75fddb9 to aed2d4a Compare September 15, 2024 03:44
@francoisfreitag

This comment was marked as resolved.

job_application.resume_link = ""
job_application.save(update_fields=["resume_link"])
with freeze_time("2023-12-12 13:37:00") as initial_invite_time:
job_application = JobApplicationFactory(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tu peux transformer le context manager en décorateur pour mieux l’indiquer et gagner un niveau d’indentation.

job_application.resume_link = ""
job_application.save(update_fields=["resume_link"])
with freeze_time("2023-12-12 13:37:00") as initial_invite_time:
job_application = JobApplicationFactory(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

L’explication du changement de ce test serait très utile en message de commit.

@tonial tonial force-pushed the alaurent/apply_filters branch from aed2d4a to 7f80dc6 Compare September 19, 2024 13:02
Because of the session used in the view details_for_company, if the time
skips too much in a test, the session is revoked and the user is logged out.

That's why I changed the whole
test_diagoriente_invite_as_employee_for_authorized_prescriber test to
use a freeze_time decorator with a tick to move forward during the test
@tonial tonial force-pushed the alaurent/apply_filters branch from 7f80dc6 to ae2e70a Compare September 19, 2024 13:31
@tonial tonial enabled auto-merge September 19, 2024 13:31
@tonial tonial added this pull request to the merge queue Sep 19, 2024
Merged via the queue into master with commit 90a17a2 Sep 19, 2024
@tonial tonial deleted the alaurent/apply_filters branch September 19, 2024 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1-recette-jetable [Payé à l’heure] Crée une recette jetable sur CC modifié Modifié dans le changelog.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants