Commit 9025264e authored by Jerome Berthier's avatar Jerome Berthier Committed by Vincent A

[banquepopulaire] fix BrowserUnavailable during iter_accounts

The former implementation was not reaching the synthesis page when
the accounts list needed to be expanded.
In this case, when facing several deferred cards in a row, the browser was not
able to perform the prevAction of the 2nd+ card.
parent 12903258
......@@ -231,6 +231,15 @@ class BanquePopulaire(LoginBrowser):
form['token'] =['token'])
# In case of prevAction maybe we have reached an expanded accounts list page, need to go back
btn ='.//button[span[text()="Retour"]]')
if len(btn):
_data =
actions =
_data['token'] =['token'])
self.location('/cyber/internet/', data=_data)
def get_accounts_list(self, get_iban=True):
......@@ -630,6 +630,7 @@ class AccountsPage(LoggedPage, MyHTMLPage):
if len(tds) >= 5 and len(tds[self.COL_COMING].xpath('.//a')) > 0:
_params = account._params.copy()
_params['dialogActionPerformed'] = 'ENCOURS_COMPTE'
_params['attribute($SEL_$%s)' % tr.attrib['id'].split('_')[0]] = tr.attrib['id'].split('_', 1)[1]
# If there is an action needed before going to the cards page, save it.
m ='dialogActionPerformed=([\w_]+)', self.url)
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