Add SetScreenSize to IConsoleDriver and fix test issues

- Added SetScreenSize(int, int) method to IConsoleDriver interface
- Implemented in ConsoleDriver base class to throw NotImplementedException
- Implemented in ConsoleDriverFacade to throw NotImplementedException
- Overridden in FakeDriver to call SetBufferSize for testing
- Updated all test files to use Application.Driver.SetScreenSize() instead of casting to FakeDriver
- Fixed FakeDriver_MockKeyPresses_Stack_Works test by clearing stack before use
- All tests now pass without casting (21 UnitTests + 16 Parallelizable FakeDriver tests)

Co-authored-by: tig <585482+tig@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-10-26 21:14:01 +00:00
parent ba531af5fd
commit c4a73d71c7
12 changed files with 39 additions and 11 deletions

View File

@@ -30,7 +30,7 @@ public class TreeTableSourceTests : IDisposable
[SetupFakeDriver]
public void TestTreeTableSource_BasicExpanding_WithKeyboard ()
{
((FakeDriver)Application.Driver!).SetBufferSize (100, 100);
Application.Driver!.SetScreenSize (100, 100);
TableView tv = GetTreeTable (out _);
tv.Style.GetOrCreateColumnStyle (1).MinAcceptableWidth = 1;
@@ -91,7 +91,7 @@ public class TreeTableSourceTests : IDisposable
[SetupFakeDriver]
public void TestTreeTableSource_BasicExpanding_WithMouse ()
{
((FakeDriver)Application.Driver!).SetBufferSize (100, 100);
Application.Driver!.SetScreenSize (100, 100);
TableView tv = GetTreeTable (out _);