gecko-dev/testing/modules
Eric Chen 4bced98a4c Bug 1922010 Change WindowsLaunchOnLogin functions that interacts with registry keys to be private r=settings-reviewers,mossop
This patch includes 4 main changes

1. Created a guard in `removeLaunchOnLogin` with `getLaunchOnLoginApproved` to make sure the setting is not already disabled before removing the registry key made by Firefox.

2. Change the method doc for `removeLaunchOnLogin` to better describe why we need to guard the function and provide necessary context.

3. Prefixed the functions called within `removeLaunchOnLogin` with "_", to signify that they should not be used as a public API. We should only call those functions after we've checked the return value of `getLaunchOnLoginApproved`.

4. Modified existing unit test, and added a new unit test to make sure `removeLaunchOnLogin` is non-op when Windows has disabled such feature.

Differential Revision: https://phabricator.services.mozilla.com/D227399
2024-11-12 14:51:10 +00:00
..
tests
AppData.sys.mjs
AppInfo.sys.mjs
Assert.sys.mjs
CoverageUtils.sys.mjs
FileTestUtils.sys.mjs
MockRegistrar.sys.mjs
MockRegistry.sys.mjs
moz.build
sinon-7.2.7.js
Sinon.sys.mjs
StructuredLog.sys.mjs
TestUtils.sys.mjs
XPCShellContentUtils.sys.mjs