do not crash if there is no operations

This commit is contained in:
Romain Bignon 2013-10-10 09:53:53 +02:00
commit 5c5cb5da8e
2 changed files with 8 additions and 0 deletions

View file

@ -320,3 +320,6 @@ class TransactionsPage(BasePage):
t.parse(date, re.sub(r'[ ]+', ' ', raw), vdate)
t.set_amount(credit, debit)
yield t
def no_operations(self):
return len(self.document.xpath('//table[@id="tbl1"]//td[@colspan]')) > 0