AltTrailingSlash tests should actually use AltDirectorySeparatorChar (#64437)
authorAdam Sitnik <adam.sitnik@gmail.com>
Fri, 28 Jan 2022 11:22:41 +0000 (12:22 +0100)
committerGitHub <noreply@github.com>
Fri, 28 Jan 2022 11:22:41 +0000 (04:22 -0700)
src/libraries/System.IO.FileSystem/tests/File/Exists.cs

index 811df24..9828ea7 100644 (file)
@@ -79,7 +79,7 @@ namespace System.IO.Tests
         [PlatformSpecific(TestPlatforms.Windows)]
         public void PathEndsInAltTrailingSlash_Windows()
         {
-            string path = GetTestFilePath() + Path.DirectorySeparatorChar;
+            string path = GetTestFilePath() + Path.AltDirectorySeparatorChar;
             Assert.False(Exists(path));
         }
 
@@ -97,7 +97,7 @@ namespace System.IO.Tests
         {
             string path = GetTestFilePath();
             File.Create(path).Dispose();
-            Assert.False(Exists(path + Path.DirectorySeparatorChar));
+            Assert.False(Exists(path + Path.AltDirectorySeparatorChar));
         }
 
         [Fact]