fix module deactivation

This commit is contained in:
Gleb Khmyznikov
2025-11-21 20:19:41 -08:00
parent 11fd2ff40d
commit 94e07420cf
3 changed files with 7 additions and 16 deletions

View File

@@ -46,14 +46,11 @@ namespace UITests_FancyZones
{
}
static DragWindowTests()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
}
[TestInitialize]
public void TestInitialize()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
// ClearOpenWindows
ClearOpenWindows();
@@ -257,7 +254,7 @@ namespace UITests_FancyZones
{
// press Shift Key to deactivate zones
Session.PressKey(Key.Shift);
Task.Delay(500).Wait();
Task.Delay(1000).Wait();
},
releaseAction: () =>
{

View File

@@ -26,11 +26,6 @@ namespace UITests_FancyZones
{
}
static LayoutApplyHotKeyTests()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
}
private static readonly EditorParameters.ParamsWrapper Parameters = new EditorParameters.ParamsWrapper
{
ProcessId = 1,
@@ -222,6 +217,8 @@ namespace UITests_FancyZones
[TestInitialize]
public void TestInitialize()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
FancyZonesEditorHelper.Files.Restore();
EditorParameters editorParameters = new EditorParameters();
FancyZonesEditorHelper.Files.ParamsIOHelper.WriteData(editorParameters.Serialize(Parameters));

View File

@@ -27,14 +27,11 @@ namespace UITests_FancyZones
{
}
static OneZoneSwitchTests()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
}
[TestInitialize]
public void TestInitialize()
{
SettingsConfigHelper.ConfigureGlobalModuleSettings("Hosts");
// kill all processes related to FancyZones Editor to ensure a clean state
Session.KillAllProcessesByName("PowerToys.FancyZonesEditor");
AppZoneHistory.DeleteFile();