From 279fb4bc9584440560f6bba371125b86820f8183 Mon Sep 17 00:00:00 2001 From: Abdullah Mansour Date: Wed, 12 Aug 2026 13:05:53 +0300 Subject: [PATCH 1/2] fix(tweaks): use canonical location service startup type --- config/tweaks.json | 2 +- pester/configs.Tests.ps1 | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/config/tweaks.json b/config/tweaks.json index cd2d35c8b3..d64a848d65 100644 --- a/config/tweaks.json +++ b/config/tweaks.json @@ -114,7 +114,7 @@ "service": [ { "Name": "lfsvc", - "StartupType": "Disable", + "StartupType": "Disabled", "OriginalType": "Manual" } ], diff --git a/pester/configs.Tests.ps1 b/pester/configs.Tests.ps1 index cf7e88809b..d29ff6ff57 100644 --- a/pester/configs.Tests.ps1 +++ b/pester/configs.Tests.ps1 @@ -428,6 +428,7 @@ Describe "UI-rendered config entries" { $tweaks = Get-WinUtilConfigObject -Name "tweaks" $requiredFields = @("Content", "category", "panel", "link") $allowedTypes = @("Button", "Combobox", "Toggle", "ToggleButton") + $allowedServiceStartupTypes = @("Automatic", "AutomaticDelayedStart", "Disabled", "Manual") $supportedButtons = Get-WinUtilButtonSwitchNames $invalidEntries = New-Object System.Collections.Generic.List[string] @@ -498,6 +499,13 @@ Describe "UI-rendered config entries" { foreach ($missingField in (Get-WinUtilMissingRequiredFields -EntryName "$($entry.Name),service" -Entry $serviceEntry -RequiredFields @("Name", "StartupType", "OriginalType"))) { $invalidEntries.Add($missingField) } + + foreach ($startupTypeField in @("StartupType", "OriginalType")) { + if ((Test-WinUtilHasNonEmptyProperty -Object $serviceEntry -Name $startupTypeField) -and + $allowedServiceStartupTypes -notcontains $serviceEntry.$startupTypeField) { + $invalidEntries.Add("$($entry.Name),service has unsupported $startupTypeField '$($serviceEntry.$startupTypeField)'") + } + } } } From 9dc0289774729eb353c26aed5b42d979ac502bfb Mon Sep 17 00:00:00 2001 From: Abdullah Mansour Date: Wed, 12 Aug 2026 13:21:23 +0300 Subject: [PATCH 2/2] test(tweaks): pin location service startup type --- pester/configs.Tests.ps1 | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pester/configs.Tests.ps1 b/pester/configs.Tests.ps1 index d29ff6ff57..49af330ecc 100644 --- a/pester/configs.Tests.ps1 +++ b/pester/configs.Tests.ps1 @@ -217,6 +217,16 @@ Describe "Tweaks config" { throw ($invalidTweaks -join "`n") } } + + It "keeps the location service disabled" -TestCases $testCase { + param([string]$Path) + + $tweaks = Get-Content -Path $Path -Raw | ConvertFrom-Json + $locationServices = @($tweaks.WPFTweaksLocation.service | Where-Object Name -eq "lfsvc") + + $locationServices | Should -HaveCount 1 + $locationServices[0].StartupType | Should -Be "Disabled" + } } Describe "Preset config" {