mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2026-01-02 01:03:29 +01:00
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:
@@ -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 _);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user