Skip to content

Commit 73a6f54

Browse files
committed
Add tests cover both backslash and slash in duplicat patterns scenarios
1 parent 7cc92a2 commit 73a6f54

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

test/Microsoft.Framework.FileSystemGlobbing.Tests/FunctionalTests.cs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,15 @@ public void Dispose()
2828
}
2929
}
3030

31-
[Fact]
32-
public void DuplicatePatterns()
31+
[Theory]
32+
[InlineData("sub/source2.cs", "sub/source2.cs")]
33+
[InlineData("sub\\source2.cs", "sub\\source2.cs")]
34+
[InlineData("sub/source2.cs", "sub\\source2.cs")]
35+
public void DuplicatePatterns(string pattern1, string pattern2)
3336
{
3437
var matcher = new Matcher();
35-
matcher.AddInclude("sub/source2.cs");
36-
matcher.AddInclude("sub/source2.cs");
38+
matcher.AddInclude(pattern1);
39+
matcher.AddInclude(pattern2);
3740

3841
ExecuteAndVerify(matcher, @"src/project",
3942
"src/project/sub/source2.cs");

0 commit comments

Comments
 (0)