Skip to content

Commit 8701c2b

Browse files
committed
Update OsSettingsResolverTest.cs
1 parent afa3381 commit 8701c2b

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

src/DiffEngine.Tests/OsSettingsResolverTest.cs

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,17 @@ public void EnvVar()
4343
Left: (temp, target) => string.Empty,
4444
Right: (temp, target) => string.Empty);
4545

46-
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
46+
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
4747
{
48-
var found = OsSettingsResolver.Resolve(new OsSupport(Windows: new OsSettings("ComSpec", "cmd.exe", launchArguments, "")), out var filePath, out var launchArgs);
49-
Assert.Equal(true, found);
50-
Assert.Equal(@"C:\Windows\System32\cmd.exe", filePath, ignoreCase: true);
48+
return;
5149
}
50+
51+
var found = OsSettingsResolver.Resolve(
52+
new(Windows: new("ComSpec", "cmd.exe", launchArguments, "")),
53+
out var filePath,
54+
out var launchArgs);
55+
Assert.Equal(true, found);
56+
Assert.Equal(@"C:\Windows\System32\cmd.exe", filePath, ignoreCase: true);
5257
}
5358

5459
public OsSettingsResolverTest(ITestOutputHelper output) :

0 commit comments

Comments
 (0)