Skip to content

Commit 670b259

Browse files
committed
- adds additional test
Signed-off-by: Vincent Biret <[email protected]>
1 parent e036750 commit 670b259

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

test/Microsoft.OpenApi.Tests/Validations/OpenApiPathsValidationTests.cs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,5 +62,21 @@ public void ValidatePathsAreUniqueDoesNotConsiderMultiParametersAsIdentical()
6262
// Assert
6363
errors.Should().BeEmpty();
6464
}
65+
[Fact]
66+
public void ValidatePathsAreUniqueConsidersMultiParametersAsIdentical()
67+
{
68+
// Arrange
69+
var paths = new OpenApiPaths
70+
{
71+
{"/drives/{drive-id}/items/{driveItem-id}/workbook/worksheets/{workbookWorksheet-id}/charts/{workbookChart-id}/image(width={width},height={height})",new OpenApiPathItem() },
72+
{"/drives/{drive-id}/items/{driveItem-id}/workbook/worksheets/{workbookWorksheet-id}/charts/{workbookChart-id}/image(width={width},height={size})",new OpenApiPathItem() },
73+
};
74+
75+
// Act
76+
var errors = paths.Validate(ValidationRuleSet.GetDefaultRuleSet());
77+
78+
// Assert
79+
errors.Should().NotBeEmpty();
80+
}
6581
}
6682
}

0 commit comments

Comments
 (0)