You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
1.1 KiB

  1. # Author: Julien Coux
  2. # Copyright 2016 Camptocamp SA
  3. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
  4. import time
  5. from . import abstract_test_foreign_currency as a_t_f_c
  6. class TestOpenItems(a_t_f_c.AbstractTestForeignCurrency):
  7. """
  8. Technical tests for Open Items Report.
  9. """
  10. def _getReportModel(self):
  11. return self.env['report_open_items']
  12. def _getQwebReportName(self):
  13. return 'account_financial_report.report_open_items_qweb'
  14. def _getXlsxReportName(self):
  15. return 'a_f_r.report_open_items_xlsx'
  16. def _getXlsxReportActionName(self):
  17. return 'account_financial_report.action_report_open_items_xlsx'
  18. def _getReportTitle(self):
  19. return 'Odoo'
  20. def _getBaseFilters(self):
  21. return {
  22. 'date_at': time.strftime('%Y-12-31'),
  23. 'company_id': self.company.id,
  24. 'foreign_currency': True,
  25. }
  26. def _getAdditionalFiltersToBeTested(self):
  27. return [
  28. {'only_posted_moves': True},
  29. {'hide_account_at_0': True},
  30. {'only_posted_moves': True, 'hide_account_at_0': True},
  31. ]