Update PowerToys Run page on settings.json change (#10204)

This commit is contained in:
Mykhailo Pylyp
2021-03-15 14:52:03 +02:00
committed by GitHub
parent d872be4310
commit 9a061d74b3
5 changed files with 50 additions and 27 deletions

View File

@@ -66,7 +66,7 @@ namespace ViewModelTests
// Initialise View Model with test Config files
Func<string, int> sendMockIPCConfigMSG = msg => { return 0; };
PowerLauncherViewModel viewModel = new PowerLauncherViewModel(mockSettingsUtils, generalSettingsRepository, sendMockIPCConfigMSG, 32, () => true);
PowerLauncherViewModel viewModel = new PowerLauncherViewModel(originalSettings, generalSettingsRepository, sendMockIPCConfigMSG, () => true);
// Verify that the old settings persisted
Assert.AreEqual(originalGeneralSettings.Enabled.PowerLauncher, viewModel.EnablePowerLauncher);
@@ -82,7 +82,6 @@ namespace ViewModelTests
// Verify that the stub file was used
var expectedCallCount = 2; // once via the view model, and once by the test (GetSettings<T>)
BackCompatTestProperties.VerifyModuleIOProviderWasRead(mockIOProvider, PowerLauncherSettings.ModuleName, expectedCallCount);
BackCompatTestProperties.VerifyGeneralSettingsIOProviderWasRead(mockGeneralIOProvider, expectedCallCount);
}