Browse Source

[FIX] account_tax_balance: improve test resilience

This test failed in an integration environment where the search returned more items than necessary.

I modified it to just check that the tax that's created some lines above appears in the search results.

@Tecnativa TT21419
pull/649/head
Jairo Llopis 4 years ago
parent
commit
1ec2893cf1
No known key found for this signature in database GPG Key ID: CFC348F9B242B08
  1. 3
      account_tax_balance/tests/test_account_tax_balance.py

3
account_tax_balance/tests/test_account_tax_balance.py

@ -108,8 +108,7 @@ class TestAccountTaxBalance(HttpCase):
# exercise search has_moves = True
taxes = self.env['account.tax'].search([('has_moves', '=', True)])
self.assertEqual(len(taxes), 1)
self.assertEqual(taxes[0].name, "Tax 10.0%")
self.assertLessEqual(tax, taxes)
# testing buttons
tax_action = tax.view_tax_lines()

Loading…
Cancel
Save