You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: TEST_CHANGE_LEDGER.md
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,8 @@
2
2
3
3
Range: `3c2e41b9..HEAD`
4
4
5
+
Note: the working tree currently includes additional, uncommitted changes (not represented in the git range above). Those are called out inline where relevant.
6
+
5
7
Purpose: An exhaustive ledger of every commit in-range that touched `**/*Tests.cs`, with a per-file classification:
6
8
7
9
-**Mechanical**: refactors/rewrites to keep tests compiling/running under new tooling (NUnit API changes, adapter-friendly asserts, mock framework swaps, formatting/cleanup) without materially changing what the test is trying to prove.
@@ -50,11 +52,16 @@ Supporting non-test `.cs` changes in this commit:
50
52
-[B4] Src/Common/Controls/DetailControls/Slice.cs — **Substantive** — changes default expansion behavior so slices only auto-expand when explicitly marked `expansion="expanded"` (reduces UI-state surprises in tests).
51
53
-[B1] Src/Common/FieldWorks/ProjectId.cs — **Substantive** — improves relative-path handling so paths with a directory component resolve under ProjectsDirectory without the “double nest” behavior.
52
54
-[B2] Src/Common/SimpleRootSite/SimpleRootSite.cs — **Substantive** — best-effort unregisters `IVwNotifyChange` notifications during close/dispose to prevent post-dispose `PropChanged` callbacks destabilizing tests.
53
-
-[B4] Src/FwCoreDlgs/FindCollectorEnv.cs — **Substantive** — fixes start-location semantics across duplicate renderings and captures WS at match offsets (stabilizes find/replace selection reconstruction).
55
+
-[B4] Src/FwCoreDlgs/FindCollectorEnv.cs — **Substantive** — fixes start-location semantics across duplicate renderings, ensures the start offset applies only to the exact selected occurrence (tag + `cpropPrev`) including strings emitted via `AddString(...)`, and captures WS at match offsets (stabilizes find/replace selection reconstruction).
56
+
57
+
Working tree follow-up (uncommitted):
58
+
59
+
-[B4] Src/FwCoreDlgs/FindCollectorEnv.cs — **Substantive** — further refines start-location application to require an exact occurrence match and avoids clearing the start location prematurely in the `AddString(...)` path; resolves the remaining `FwFindReplaceDlgTests` failures under VSTest.
54
60
-[B4] Src/FwCoreDlgs/FwFindReplaceDlg.cs — **Substantive** — TE-1658: WS-only replace behavior (empty Find text + Match WS) no longer advances incorrectly; adds selection restoration + WS propagation.
55
61
-[B9] Src/xWorks/CssGenerator.cs — **Substantive** — avoids ExCSS crashes on `inherit` by using `none`/`unset` (and correct `UnitType.Ident`) to keep CSS generation deterministic.
56
62
-[C2] Src/xWorks/DictionaryConfigManager.cs — **Substantive** — keeps rename operation defensive (revert/refresh on protected items) to match test expectations.
57
63
-[D1] Build/Src/FwBuildTasks/RegFreeCreator.cs — **Mechanical** — fixes a node selection bug when adding/replacing CLR class entries in reg-free manifests.
64
+
-[D1] test.ps1 — **Mechanical** — mitigates a VSTest multi-assembly edge case where `vstest.console.exe` returns exit code `-1` even when TRX reports 0 failures, by retrying per-assembly and aggregating exit codes; emits per-assembly TRX + console logs to aid isolation.
Copy file name to clipboardExpand all lines: TEST_UPDATES_FROM_MODERNIZATION.md
+18-16Lines changed: 18 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -74,7 +74,7 @@ For the complete classification of “baseline ignore was removed/reintroduced
74
74
- In [TEST_CHANGE_LEDGER.md](TEST_CHANGE_LEDGER.md) under commit `65f81dc…`, WinForms-heavy fixtures (e.g., `StVcTests`, `FwFindReplaceDlgTests`) were moved toward STA and explicit layout/root creation.
75
75
- In the same commit, the underlying find/replace implementation was adjusted (`FindCollectorEnv`, `FwFindReplaceDlg`) to make selection reconstruction and WS-only search/replace behavior more deterministic under isolation.
76
76
- UI-state defaults that influence tests were also tightened (e.g., `Slice` expansion now only auto-expands when explicitly marked).
77
-
-Note: several `FwFindReplaceDlgTests`still fail today; those are tracked in the TODO section below.
77
+
-Follow-up: `FwFindReplaceDlgTests`are now passing under VSTest after refining `FindCollectorEnv` start-location semantics for the `AddString(...)` rendering path and ensuring the start offset only applies to the exact selected occurrence of the string property.
78
78
79
79
#### B5) ICU data discovery (ICU_DATA)
80
80
@@ -147,6 +147,18 @@ For the complete classification of “baseline ignore was removed/reintroduced
147
147
- Why this is treated as mechanical:
148
148
- These changes generally don’t alter product behavior; they’re required to keep tests buildable/runnable and reporting correctly under the modern runner.
- A full-suite run that invoked `vstest.console.exe` with multiple test assemblies returned exit code `-1`, causing `test.ps1` to report `[FAIL] ... exit code: -1`.
154
+
- The generated TRX indicated `failed="0"` (i.e., no failing tests), suggesting the exit code was unreliable for that scenario.
155
+
- Why modernization surfaced it:
156
+
- Moving from prior runners to VSTest changes process topology (testhost/execution isolation) and how failures are reported. In practice, “multi-assembly + VSTest” occasionally yields a non-specific `-1` even without test failures.
157
+
- Fix rationale (root cause):
158
+
- We treat the TRX/test results as the source of truth and make the orchestration resilient: when the multi-assembly invocation returns `-1`, `test.ps1` retries per assembly and aggregates exit codes.
159
+
- This preserves strictness (real failures still fail the run) while avoiding false negatives caused by a runner edge case.
160
+
- The per-assembly retry also produces actionable evidence: per-assembly TRX (`<AssemblyName>_<timestamp>.trx`) and per-assembly console logs (`vstest.<AssemblyName>.console.log`) in `Output\<Configuration>\TestResults`.
161
+
150
162
## Fishy / uncertain mappings (worth a quick human review)
151
163
152
164
Nothing here looks *obviously* off-scope for “stabilize tests under VSTest”, but these items do touch behavior enough that it’s reasonable to sanity-check intent:
@@ -171,21 +183,11 @@ Nothing here looks *obviously* off-scope for “stabilize tests under VSTest”,
171
183
172
184
## Current failing tests (TODO)
173
185
174
-
As of TRX: `Output\Debug\TestResults\johnm_SIL-XPS_2025-12-19_10_18_05.trx` (see `Output\Debug\TestResults\vstest.console.log`), the failing set is:
175
-
176
-
-`FwFindReplaceDlgTests.FindNextFromWithinMatchingWord` — selection verify mismatch (expected 1, was 0)
177
-
-`FwFindReplaceDlgTests.FindNextWithMatch` — expected True, was False
178
-
-`FwFindReplaceDlgTests.FindNextWithNoMatchAfterWrap` — expected True, was False
179
-
-`FwFindReplaceDlgTests.FindWithMatchCase` — expected True, was False
180
-
-`FwFindReplaceDlgTests.FindWithMatchDiacritics` — selection verify mismatch (expected 1, was 0)
181
-
-`FwFindReplaceDlgTests.InitialFindPrevWithMatch` — selection verify mismatch (expected 2, was 0)
182
-
-`FwFindReplaceDlgTests.InitialFindPrevWithMatchAfterWrap` — selection verify mismatch (expected 2, was 0)
183
-
-`FwFindReplaceDlgTests.ReplaceTextAfterFootnote` — TsString mismatch (expected `BlaQlah!`, actual `Blah, blah, blah!`)
184
-
-`FwFindReplaceDlgTests.ReplaceWithMatchWs_EmptyFindText` — selection verify mismatch (expected 3, was 7)
185
-
186
-
Suggested next debugging focus:
187
-
- Re-check `DummyFwFindReplaceDlg.VerifySelection(...)` invariants under VSTest isolation.
188
-
- Determine whether failure is caused by selection reconstruction, wrap state, or view initialization ordering in the dummy view.
186
+
As of the most recent TRX in `Output\Debug\TestResults` (see `Output\Debug\TestResults\vstest.console.log`), there are no remaining failures in `FwFindReplaceDlgTests`.
187
+
188
+
Note: if a full-suite run ever reports `[FAIL] ... exit code: -1` while TRX shows 0 failures, `test.ps1` will retry per-assembly and the per-assembly TRX/logs should be used to confirm whether there are any real failures.
if (-not$ListTests-and$testDlls.Count-gt1-and$script:testExitCode-eq-1) {
469
+
Write-Host"[WARN] vstest.console.exe returned exit code -1 with multiple test assemblies. Retrying per-assembly to isolate failures."-ForegroundColor Yellow
0 commit comments