feat: Implement container customization and add Portainer installation/removal playbooks.
Tests / Backend Tests (Python) (3.10) (push) Has been cancelled
Tests / Backend Tests (Python) (3.11) (push) Has been cancelled
Tests / Backend Tests (Python) (3.12) (push) Has been cancelled
Tests / Frontend Tests (JS) (push) Has been cancelled
Tests / Integration Tests (push) Has been cancelled
Tests / All Tests Passed (push) Has been cancelled

This commit is contained in:
2025-12-27 11:02:24 -05:00
parent 661d005fc7
commit 8affa0f8b7
30 changed files with 1767 additions and 22 deletions
+38
View File
@@ -686,4 +686,42 @@ describe('main.js - Ad-Hoc widget regression', () => {
// Since only 2 are displayed but 3 are loaded, load-more must be visible.
expect(document.getElementById('adhoc-widget-load-more').classList.contains('hidden')).toBe(false);
});
it('does not crash structured playbook viewer when parsedOutput.msg is an object', async () => {
await import('../../app/main.js');
const dash = new window.DashboardManager();
dash.escapeHtml = (s) => String(s ?? '');
const parsedOutput = {
plays: [
{
name: 'Test Play',
tasks: [
{
name: 'Task 1',
hostResults: [
{
hostname: 'host1',
status: 'ok',
parsedOutput: { msg: { hello: 'world', code: 200 } }
}
]
}
]
}
],
recap: {
host1: { ok: 1, changed: 0, failed: 0, skipped: 0, unreachable: 0 }
},
metadata: { playbookName: 'dummy.yml' },
stats: { totalHosts: 1, totalTasks: 1 }
};
expect(() => dash.renderTaskHierarchy(parsedOutput)).not.toThrow();
const html = dash.renderTaskHierarchy(parsedOutput);
expect(html).toContain('host1');
expect(html).toContain('"hello"');
});
});