Skip to content

Commit

Permalink
[wasm][tests] PathIsRooted tests failing
Browse files Browse the repository at this point in the history
- skip subtest mono#9 if WASM
- To fix issue mono#18933 we set the AltDirectorySeparatorChar as well.  This causes the `Assert.IsTrue (!Path.IsPathRooted ("\\"), "IsPathRooted mono#9");` to fail. Path.IsPathFullyQualified Method handles paths that use both the DirectorySeparatorChar and the AltDirectorySeparatorChar characters.
  • Loading branch information
kjpou1 authored and monojenkins committed Apr 11, 2020
1 parent 8786e48 commit 8f49033
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions mcs/class/corlib/Test/System.IO/PathTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -977,7 +977,13 @@ public void IsPathRooted ()
Assert.IsTrue (Path.IsPathRooted ("\\"), "IsPathRooted #16");
Assert.IsTrue (Path.IsPathRooted ("\\\\"), "IsPathRooted #17");
} else {
// To fix issue https://github.com/mono/mono/issues/18933 we set the AltDirectorySeparatorChar as well.
// This causes the Assert.IsTrue (!Path.IsPathRooted ("\\"), "IsPathRooted #09"); to fail.
// Path.IsPathFullyQualified Method handles paths that use both the DirectorySeparatorChar
// and the AltDirectorySeparatorChar characters.
#if !WASM
Assert.IsTrue (!Path.IsPathRooted ("\\"), "IsPathRooted #09");
#endif
Assert.IsTrue (!Path.IsPathRooted ("\\\\"), "IsPathRooted #10");
Assert.IsTrue (!Path.IsPathRooted ("z:"), "IsPathRooted #11");
}
Expand Down

0 comments on commit 8f49033

Please sign in to comment.