mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Some code cleanup work (#10698)
* Move Utils.GetUserConfigurationDirectory to Platform.ConfigDirectory * Unify the use of Platform.ConfigDirectory and Platform.CacheDirectory
This commit is contained in:
1 parent
8cf9c01800
commit
ec105da3f1
11 files changed
+33
-62
No files matched your search
@@ -9,7 +9,7 @@ Describe "Telemetry for shell startup" -Tag CI {
|
||||
BeforeAll {
|
||||
# if the telemetry file exists, move it out of the way
|
||||
# the member is internal, but we can retrieve it via reflection
|
||||
$cacheDir = [System.Management.Automation.Platform].GetMember("CacheDirectory","NonPublic,Static").GetMethod.Invoke($null, $null)
|
||||
$cacheDir = [System.Management.Automation.Platform].GetField("CacheDirectory","NonPublic,Static").GetValue($null)
|
||||
$uuidPath = Join-Path -Path $cacheDir -ChildPath telemetry.uuid
|
||||
$uuidFileExists = Test-Path -Path $uuidPath
|
||||
if ( $uuidFileExists ) {
|
||||
|
||||
Reference in new issue
Block a user