From 6b1b3c7997e95e76b245c7b174443595fc9012a0 Mon Sep 17 00:00:00 2001 From: Jeremy Kuhne Date: Wed, 20 Jun 2018 10:40:13 -0700 Subject: [PATCH] Tests for dotnet/corefx#30263 fix (dotnet/corefx#30374) * Tests for dotnet/corefx#30263 fix Goes with https://github.com/dotnet/coreclr/pull/18460 * Add case for `C:\` to `D:\` Commit migrated from https://github.com/dotnet/corefx/commit/eb4bb7ff28d639dcd9fd0c505d78c6196a569f57 --- .../tests/System/IO/Path.GetRelativePath.cs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/libraries/System.Runtime.Extensions/tests/System/IO/Path.GetRelativePath.cs b/src/libraries/System.Runtime.Extensions/tests/System/IO/Path.GetRelativePath.cs index 36a03d6..3f48bfd 100644 --- a/src/libraries/System.Runtime.Extensions/tests/System/IO/Path.GetRelativePath.cs +++ b/src/libraries/System.Runtime.Extensions/tests/System/IO/Path.GetRelativePath.cs @@ -17,12 +17,26 @@ namespace System.IO.Tests [InlineData(@"C:\", @"C:\b", @"b")] [InlineData(@"C:\a", @"C:\b", @"..\b")] [InlineData(@"C:\a", @"C:\b\", @"..\b\")] + [InlineData(@"C:\a\b", @"C:\a", @"..")] + [InlineData(@"C:\a\b", @"C:\a\", @"..")] + [InlineData(@"C:\a\b\", @"C:\a", @"..")] + [InlineData(@"C:\a\b\", @"C:\a\", @"..")] + [InlineData(@"C:\a\b\c", @"C:\a\b", @"..")] + [InlineData(@"C:\a\b\c", @"C:\a\b\", @"..")] + [InlineData(@"C:\a\b\c", @"C:\a", @"..\..")] + [InlineData(@"C:\a\b\c", @"C:\a\", @"..\..")] + [InlineData(@"C:\a\b\c\", @"C:\a\b", @"..")] + [InlineData(@"C:\a\b\c\", @"C:\a\b\", @"..")] + [InlineData(@"C:\a\b\c\", @"C:\a", @"..\..")] + [InlineData(@"C:\a\b\c\", @"C:\a\", @"..\..")] [InlineData(@"C:\a\", @"C:\b", @"..\b")] [InlineData(@"C:\a", @"C:\a\b", @"b")] [InlineData(@"C:\a", @"C:\A\b", @"b")] [InlineData(@"C:\a", @"C:\b\c", @"..\b\c")] [InlineData(@"C:\a\", @"C:\a\b", @"b")] + [InlineData(@"C:\", @"D:\", @"D:\")] [InlineData(@"C:\", @"D:\b", @"D:\b")] + [InlineData(@"C:\", @"D:\b\", @"D:\b\")] [InlineData(@"C:\a", @"D:\b", @"D:\b")] [InlineData(@"C:\a\", @"D:\b", @"D:\b")] [InlineData(@"C:\ab", @"C:\a", @"..\a")] -- 2.7.4