"""Tests for fusion_account_balance MV.""" from odoo.tests.common import TransactionCase, tagged @tagged('post_install', '-at_install') class TestAccountBalanceMV(TransactionCase): def test_mv_exists_and_is_queryable(self): # Force initial refresh, then make sure the model can read it. self.env['fusion.account.balance.mv']._refresh(concurrently=False) rows = self.env['fusion.account.balance.mv'].search([], limit=5) self.assertIsNotNone(rows) def test_mv_refresh_concurrent(self): # Try concurrent refresh; should either succeed or fall back gracefully. try: self.env['fusion.account.balance.mv']._refresh(concurrently=True) except Exception as e: self.fail(f"MV refresh raised: {e}")