Skip to content

Commit

Permalink
Use OrdinalIgnoreCase
Browse files Browse the repository at this point in the history
  • Loading branch information
vbreuss committed Oct 10, 2023
1 parent 90cda37 commit 812dc61
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ public void
Skip.IfNot(Test.RunsOnWindows);

string currentDirectory = FileSystem.Directory.GetCurrentDirectory();
string otherDrive = currentDirectory.Substring(0, 1) == "C" ? "D" : "C";
string otherDrive = currentDirectory
.Substring(0,1)
.Equals("c", StringComparison.OrdinalIgnoreCase) ? "D" : "C";
string input = $"{otherDrive}:test.txt";
string expectedFullPath = $@"{otherDrive}:\test.txt";

Expand Down

0 comments on commit 812dc61

Please sign in to comment.