Commit 26935e09 authored by Célande Adrien's avatar Célande Adrien Committed by Vincent A

[lcl] send message for TransferBankError

By default not indicating message make of the string a description
which is not what we want.
We want the message to be send to the client, not stocked in db.

Closes: 14296@zendesk
parent 221ab27d
...@@ -1162,7 +1162,7 @@ class TransferPage(LoggedPage, HTMLPage): ...@@ -1162,7 +1162,7 @@ class TransferPage(LoggedPage, HTMLPage):
# This aims to track input errors. # This aims to track input errors.
script_error = CleanText(u"//script[contains(text(), 'if (\"true\"===\"true\")')]")(self.doc) script_error = CleanText(u"//script[contains(text(), 'if (\"true\"===\"true\")')]")(self.doc)
if script_error: if script_error:
raise TransferBankError(CleanText().filter(html2text(re.search(u'\.html\("(.*?)"\)', script_error).group(1)))) raise TransferBankError(message=CleanText().filter(html2text(re.search(u'\.html\("(.*?)"\)', script_error).group(1))))
def can_transfer(self, account_transfer_id): def can_transfer(self, account_transfer_id):
for div in self.doc.xpath('//div[input[@id="indexCompteEmetteur"]]//div[@class="infoCompte" and not(@title)]'): for div in self.doc.xpath('//div[input[@id="indexCompteEmetteur"]]//div[@class="infoCompte" and not(@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