[FIX] account_financial_report: Fix tests

Parially revert test changes in ac4eef006f

This is needed in contexts where a different localization and accouting configuration is loaded
pull/781/head
João Marques 2021-05-12 11:14:23 +01:00
parent f90142c253
commit a16498dcdb
1 changed files with 7 additions and 0 deletions

View File

@ -240,6 +240,13 @@ class TestTrialBalanceReport(common.TransactionCase):
self.assertTrue(self.account200 in self.group2.compute_account_ids) self.assertTrue(self.account200 in self.group2.compute_account_ids)
def test_01_account_balance_computed(self): def test_01_account_balance_computed(self):
# Change code of the P&L for not being automatically included
# in group 1 balances
earning_accs = self.env["account.account"].search(
[("user_type_id", "=", self.env.ref("account.data_unaffected_earnings").id)]
)
for acc in earning_accs:
acc.code = "999" + acc.code
# Generate the general ledger line # Generate the general ledger line
res_data = self._get_report_lines() res_data = self._get_report_lines()
trial_balance = res_data["trial_balance"] trial_balance = res_data["trial_balance"]