A set of routes with different subroutes after a parameter overwrite previous routes causing mismatch.
In the BlazorRouteTests amend the code for MatchesTemplateWithParameters as follows:
[Fact]publicvoidMatchesTemplateWithParameters(){string[]templates={"/Cats/{id}/Breed","/Cats/{id}","/Cats/{id}/Owner",};vartarget=newBlazorRoutes(templates);Assert.True(target.Contains("cats/42"));Assert.True(target.Contains("cats/42/owner"));Assert.True(target.Contains("cats/42/breed"));}The first two tests pass but the second fails, because the last parameter route (owner) overwrites the prior one.
A set of routes with different subroutes after a parameter overwrite previous routes causing mismatch.
In the
BlazorRouteTestsamend the code forMatchesTemplateWithParametersas follows:The first two tests pass but the second fails, because the last parameter route (owner) overwrites the prior one.