Une MAJ de sécurité est nécessaire sur notre version actuelle. Elle sera effectuée lundi 02/08 entre 12h30 et 13h. L'interruption de service devrait durer quelques minutes (probablement moins de 5 minutes).

Commit 950c2d35 authored by Swergas's avatar Swergas
Browse files

at the end of each vote, decide randomly wether we close and reopen the browser or not

parent f21e1e15
Pipeline #55619 passed with stages
in 13 minutes and 25 seconds
......@@ -959,10 +959,11 @@ pris en compte.
# In a following pass, he checks his mailbox to find a new email with confirmation of his vote, and verifies the value of the smart ballot tracker written in this email is the same as the one he noted. This verification is done in a separated pass because of an optimization, so that we only re-read and re-populate the sendmail_fake text file once for all users.
# He closes the window (there is no log-out link, because user is not logged in: credentials are not remembered)
# TODO: Is it really mandatory for the test to close the window? Re-opening a browser takes much more time, compared to just navigating to another URL.
browser.quit()
self.browser = initialize_browser()
browser = self.browser
# It is not really mandatory for the test to close the window. Re-opening a browser takes much more time, compared to just navigating to another URL. So actually to save execution time, we choose to close the window only sometimes, randomly.
if random.randint(0, 10) <= 3:
browser.quit()
self.browser = initialize_browser()
browser = self.browser
# Start another pass, where we re-read and re-populate the sendmail_fake text file once for all users.
voters = repopulate_vote_confirmations_for_voters_from_sent_emails(self.fake_sent_emails_manager, voters, ELECTION_TITLE)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment