test(admin): wait for the addon list's empty state after a failed load

The empty state shows once loading has ended, which can come a render after
the toast; the test read it in the same tick and failed now and then.
This commit is contained in:
Maurice
2026-10-20 05:51:22 +00:00
parent 9f0caf8539
commit f79b2020d6
@@ -106,7 +106,8 @@ describe('MAdminAddonManager', () => {
render(<><ToastContainer /><MAdminAddonManager /></>);
await screen.findByText('Failed to update addon');
expect(screen.getByText('No addons available')).toBeInTheDocument();
// The empty state follows the toast once loading has ended, not in the same render.
expect(await screen.findByText('No addons available')).toBeInTheDocument();
});
it('FE-MOB-AADD-005: trip addons render with the section band, catalog label and type badge', async () => {