Skip to content

[WIP] Create continuation pull request for FakeDriver tasks#4356

Closed
Copilot wants to merge 1 commit into
v2_developfrom
copilot/rename-onsizechanged-to-onscreenchanged
Closed

[WIP] Create continuation pull request for FakeDriver tasks#4356
Copilot wants to merge 1 commit into
v2_developfrom
copilot/rename-onsizechanged-to-onscreenchanged

Conversation

Copilot AI commented Oct 27, 2025

Copy link
Copy Markdown
Contributor

Thanks for asking me to work on this. I will get started on it and keep this PR's description up to date as I form a plan and make progress.

Original prompt

Objective

Create a corrected continuation pull request that starts from the exact code state of the original branch used in PR #4347 (copilot/move-fakedriver-to-terminal-drivers). Because GitHub does not allow two open PRs from the same head branch to the same base branch, this new PR will use a new branch that is an exact copy of the commit currently at the head of copilot/move-fakedriver-to-terminal-drivers (HEAD commit from #4347) and will then proceed with the deferred tasks.

Starting Point

Deferred Tasks To Implement In This PR

  1. Rename OnSizeChanged -> OnScreenChanged (and associated event/property names if applicable).
    • Add XML docs; if public surface exists, add [Obsolete("Use OnScreenChanged")] shim.
  2. Fix AutoInitShutdownAttribute.FakeResize to call SetScreenSize instead of mutating rows/cols directly; ensure parallel safety.
  3. Audit TerminalGuiFluentTesting (fluent test infra) and migrate any residual custom FakeDriver code to the library FakeDriver; remove duplicates.
  4. Consistent exception messages for unsupported SetScreenSize in other drivers ("SetScreenSize is only supported by FakeDriver for test scenarios.").
  5. Add / update tests:
    • Resize event firing (after rename).
    • Buffer integrity after multiple resizes (no stale runes/attributes/ colors).
    • FakeResize helper usage scenario.
    • Fluent tests exercising keyboard + mouse + resize path with built-in FakeDriver only.
  6. Documentation polish (inline + XML) describing Screen as source of truth; Rows/Cols read-only; SetScreenSize intent.
  7. Final cleanup: remove dead code, ensure naming consistency (avoid mixed BufferSize/ScreenSize terms; prefer ScreenSize/Screen terminology).
  8. Run and confirm full test suites (UnitTests, UnitTestsParallelizable, IntegrationTests) all pass; update PR description with test counts.

Acceptance Criteria

  • All existing tests pass plus new tests added for event rename and buffer integrity.
  • No lingering references to old naming (OnSizeChanged) outside Obsolete shim (if needed).
  • Fluent testing uses only library FakeDriver.
  • AutoInitShutdownAttribute.FakeResize deterministic and isolated (no state leak between parallel tests).
  • Clear, consistent developer-facing messages and docs.

Implementation Plan (Commit Strategy)

A. Branch creation & initial PR (no code changes yet).
B. Mechanical rename & docs + Obsolete shim if required.
C. AutoInitShutdownAttribute.FakeResize refactor + tests.
D. Fluent infra audit & migration commit.
E. Tests for resize event + buffer integrity + fluent scenarios.
F. Exception message normalization.
G. Documentation polish & cleanup.
H. Final test run + description update.

AI Model Identification

AI Model Performing This Work: GitHub Copilot Chat (model: gpt-4.1 or successor) acting as coding agent.

References

This PR supersedes #4355 and continues the work from #4347 using a branch copied from its original head.

This pull request was created as a result of the following prompt from Copilot chat.

Objective

Create a corrected continuation pull request that starts from the exact code state of the original branch used in PR #4347 (copilot/move-fakedriver-to-terminal-drivers). Because GitHub does not allow two open PRs from the same head branch to the same base branch, this new PR will use a new branch that is an exact copy of the commit currently at the head of copilot/move-fakedriver-to-terminal-drivers (HEAD commit from #4347) and will then proceed with the deferred tasks.

Starting Point

Deferred Tasks To Implement In This PR

  1. Rename OnSizeChanged -> OnScreenChanged (and associated event/property names if applicable).
    • Add XML docs; if public surface exists, add [Obsolete("Use OnScreenChanged")] shim.
  2. Fix AutoInitShutdownAttribute.FakeResize to call SetScreenSize instead of mutating rows/cols directly; ensure parallel safety.
  3. Audit TerminalGuiFluentTesting (fluent test infra) and migrate any residual custom FakeDriver code to the library FakeDriver; remove duplicates.
  4. Consistent exception messages for unsupported SetScreenSize in other drivers ("SetScreenSize is only supported by FakeDriver for test scenarios.").
  5. Add / update tests:
    • Resize event firing (after rename).
    • Buffer integrity after multiple resizes (no stale runes/attributes/ colors).
    • FakeResize helper usage scenario.
    • Fluent tests exercising keyboard + mouse + resize path with built-in FakeDriver only.
  6. Documentation polish (inline + XML) describing Screen as source of truth; Rows/Cols read-only; SetScreenSize intent.
  7. Final cleanup: remove dead code, ensure naming consistency (avoid mixed BufferSize/ScreenSize terms; prefer ScreenSize/Screen terminology).
  8. Run and confirm full test suites (UnitTests, UnitTestsParallelizable, IntegrationTests) all pass; update PR description with test counts.

Acceptance Criteria

  • All existing tests pass plus new tests added for event rename and buffer integrity.
  • No lingering references to old naming (OnSizeChanged) outside Obsolete shim (if needed).
  • Fluent testing uses only library FakeDriver.
  • AutoInitShutdownAttribute.FakeResize deterministic and isolated (no state leak between parallel tests).
  • Clear, consistent developer-facing messages and docs.

Implementation Plan (Commit Strategy)

A. Branch creation & initial PR (no code changes yet).
B. Mechanical rename & docs + Obsolete shim if required.
C. AutoInitShutdownAttribute.FakeResize refactor + tests.
D. Fluent infra audit & migration commit.
E. Tests for resize event + buffer integrity + fluent scenarios.
F. Exception message normalization.
G. Documentation polish & cleanup.
H. Final test run + description update.

AI Model Identification

AI Model Performing This Work: GitHub Copilot Chat (model: gpt-4.1 or successor) acting as coding agent.

References

This PR supersedes #4355 and continues the work from #4347 using a branch copied from its original head.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI assigned Copilot and tig Oct 27, 2025
@tig tig closed this Oct 27, 2025
Copilot AI requested a review from tig October 27, 2025 03:22
@tig tig deleted the copilot/rename-onsizechanged-to-onscreenchanged branch May 8, 2026 03:11
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.

2 participants