Compare commits

...

1 Commits

Author SHA1 Message Date
Timmy
f3167dafb3 test(#122): Add test for completed Unbuilding suppressing alignment UI
Some checks failed
Accessibility Checks / a11y-audit (pull_request) Successful in 16s
Smoke Test / smoke (pull_request) Failing after 22s
The fix in renderAlignment() already checks both G.dismantleActive
and G.dismantleComplete, but only the active case had a test.

Added: "completed Unbuilding suppresses pending alignment event UI"
- Sets G.pendingAlignment = true and G.dismantleComplete = true
- Verifies alignment-ui is empty and hidden

All 11 dismantle tests pass.

Closes #122
2026-04-14 22:25:19 -04:00

View File

@@ -275,6 +275,18 @@ test('active Unbuilding suppresses pending alignment event UI', () => {
assert.equal(document.getElementById('alignment-ui').style.display, 'none');
});
test('completed Unbuilding suppresses pending alignment event UI', () => {
const { G, renderAlignment, document } = loadBeacon({ includeRender: true });
G.pendingAlignment = true;
G.dismantleComplete = true;
renderAlignment();
assert.equal(document.getElementById('alignment-ui').innerHTML, '');
assert.equal(document.getElementById('alignment-ui').style.display, 'none');
});
test('stage five lasts long enough to dissolve every resource card', () => {
const { G, Dismantle } = loadBeacon();