fix Spelling error

This commit is contained in:
Zhaopeng Wang (from Dev Box)
2025-04-29 05:15:43 +08:00
parent 85c7e3b5ef
commit ff8a5163ef
2 changed files with 5 additions and 5 deletions

View File

@@ -45,7 +45,7 @@ namespace Microsoft.PowerToys.UITest
Console.WriteLine($"Running tests on platform: {Environment.GetEnvironmentVariable("platform")}");
if (isInPipeline)
{
NativeMethods.ChangeDispalyResolution(1920, 1080);
NativeMethods.ChangeDisplayResolution(1920, 1080);
NativeMethods.GetMonitorInfo();
// Escape Popups before starting
@@ -534,7 +534,7 @@ namespace Microsoft.PowerToys.UITest
}
}
public static void ChangeDispalyResolution(int PelsWidth, int PelsHeight)
public static void ChangeDisplayResolution(int PelsWidth, int PelsHeight)
{
Screen screen = Screen.PrimaryScreen!;
if (screen.Bounds.Width == PelsWidth && screen.Bounds.Height == PelsHeight)

View File

@@ -528,19 +528,19 @@ namespace Microsoft.FancyZones.UITests
int nowWidth = UITestBase.MonitorInfoData.Monitors[UITestBase.MonitorInfoData.Monitors.Count - 1].PelsWidth;
int height = UITestBase.MonitorInfoData.Monitors[0].PelsHeight;
int width = UITestBase.MonitorInfoData.Monitors[0].PelsWidth;
UITestBase.NativeMethods.ChangeDispalyResolution(width, height);
UITestBase.NativeMethods.ChangeDisplayResolution(width, height);
this.AttachPowertoySetting();
this.AttachFancyZonesEditor();
var resolution = this.Session.Find<Element>(By.AccessibilityId("Monitors")).Find<Element>("Monitor 1").Find<Element>(By.AccessibilityId("ResolutionText"));
if (resolution.Text != "640 × 480")
{
this.CloseFancyZonesEditor();
UITestBase.NativeMethods.ChangeDispalyResolution(nowWidth, nowHeight);
UITestBase.NativeMethods.ChangeDisplayResolution(nowWidth, nowHeight);
Assert.AreEqual("640 × 480", resolution.Text);
}
this.CloseFancyZonesEditor();
UITestBase.NativeMethods.ChangeDispalyResolution(nowWidth, nowHeight);
UITestBase.NativeMethods.ChangeDisplayResolution(nowWidth, nowHeight);
}
private void OpenFancyZonesPanel(bool launchAsAdmin = false)