Skip to content

Commit a0939b8

Browse files
committed
DisableScrubUserProfileTests
1 parent d0277ed commit a0939b8

File tree

5 files changed

+20
-2
lines changed

5 files changed

+20
-2
lines changed

src/StaticSettingsTests/DisableDirScrubbingTests.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
{
44
public DisableDirScrubbingTests()
55
{
6-
VerifierSettings.DontScrubUserProfile();
76
VerifierSettings.DontScrubSolutionDirectory();
87
VerifierSettings.DontScrubProjectDirectory();
98
var solutionDirectory = AttributeReader.GetSolutionDirectory();
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
C:\Users\simon
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
 C:\Users\simon
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
public class DisableScrubUserProfileTests :
2+
BaseTest
3+
{
4+
string profileDir = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile);
5+
6+
public DisableScrubUserProfileTests() =>
7+
VerifierSettings.DontScrubUserProfile();
8+
9+
[Fact(Skip = "explicit")]
10+
public Task Simple() =>
11+
Verify(profileDir);
12+
13+
[Fact(Skip = "explicit")]
14+
public Task Wrapped() =>
15+
Verify($" {profileDir} ");
16+
}

src/Verify/Serialization/Scrubbers/ApplyScrubbers.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ public static void UseAssembly(string? solutionDir, string projectDir)
4444
replacements[altTempPath + altDirSeparator] = "{TempPath}";
4545
replacements[altTempPath] = "{TempPath}";
4646

47-
if (VerifierSettings.scrubUserProfile && RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
47+
if (VerifierSettings.scrubUserProfile &&
48+
RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
4849
{
4950
var profileDir = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile);
5051
if (!string.IsNullOrWhiteSpace(profileDir))

0 commit comments

Comments
 (0)