Skip to content

Cover GUI helpers that work on live WPF controls - #83

Merged
BiosSystem merged 1 commit into
masterfrom
feature/gui-tests-epic-q-3
Sep 25, 2026
Merged

BiosSystem merged 1 commit into
masterfrom
feature/gui-tests-epic-q-3

Conversation

@BiosSystem

Copy link
Copy Markdown
Owner

Third GUI test slice (Epic Q), and the pattern for the remaining control-bound helpers. ConvertTo-NormalizedCheckboxState, Set-TriStatePresetCheckBoxState, and Test-ComboBoxContainsMatch take real CheckBox/ComboBox objects, so each scenario builds the control, calls the function, and asserts the resulting state.

WPF construction needs STA and the unit job runs under pwsh (MTA), so every scenario runs in its own STA runspace (same in-process AppDomain, so returned values are real, not serialized). Verified under both STA and MTA parents.

Locks down the subtle behavior:

  • a checkbox flagged indeterminate-before-click normalizes to checked and the one-shot flag clears;
  • the tri-state preset box is unchecked / checked / indeterminate for none / all / partial selections, and disabled when the group is empty;
  • combo match finds text in both a ComboBoxItem and a plain string item.

Wired into test.yml. Test-only; no product change, no release. Local: static validation clean (138 files), full Tests\Unit 252 passed / 0 failed (7 new).

Third GUI test slice, and the pattern for the rest. ConvertTo-NormalizedCheckboxState,
Set-TriStatePresetCheckBoxState, and Test-ComboBoxContainsMatch take real CheckBox
and ComboBox objects, so each scenario builds the control, calls the function, and
checks the resulting state.

WPF construction needs an STA thread and the unit job runs under pwsh (MTA), so
every scenario runs in its own STA runspace, which also loads the WPF assemblies
away from the test host. Verified under both STA and MTA parents.

Covers the subtle cases: a checkbox that was indeterminate before its click is
normalized to checked, and the tri-state preset box goes unchecked / checked /
indeterminate for none / all / partial selections. Wired into test.yml.
@BiosSystem
BiosSystem merged commit fd621d8 into master Sep 25, 2026
1 check passed
@BiosSystem
BiosSystem deleted the feature/gui-tests-epic-q-3 branch September 25, 2026 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant