Base:
44 references to ToString
Microsoft.AspNetCore.OpenApi (1)
Extensions\JsonNodeSchemaExtensions.cs (1)
241
schema[OpenApiSchemaKeywords.PatternKeyword] = regexRouteConstraint.Constraint.
ToString
();
Microsoft.AspNetCore.Routing.Tests (9)
DefaultParameterPolicyFactoryTest.cs (1)
357
Assert.Equal("\\\\d{1,2}", constraint.Constraint.
ToString
());
Patterns\RoutePatternFactoryTest.cs (8)
242
c => Assert.Equal("foo", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()),
243
c => Assert.Equal("bar", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()),
244
c => Assert.Equal("^(baz)$", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()));
280
c => Assert.Equal("^(fizz)$", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()));
287
c => Assert.Equal("foo", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()),
288
c => Assert.Equal("bar", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()),
289
c => Assert.Equal("^(baz)$", Assert.IsType<RegexRouteConstraint>(c.ParameterPolicy).Constraint.
ToString
()),
375
Assert.Equal("^(foo)$", regex.Constraint.
ToString
());
Microsoft.Build.BuildCheck.UnitTests (30)
EditorConfig_Tests.cs (30)
124
Assert.Equal("^.*/abc$", matcher.Regex.
ToString
());
136
Assert.Equal("^.*/[^/]*$", matcher.Regex.
ToString
());
147
Assert.Equal("^.*/[^/]*\\.cs$", matcher.Regex.
ToString
());
164
Assert.Equal("^.*/.*\\.cs$", matcher.Regex.
ToString
());
174
Assert.Equal("^.*/\\.\\.\\.$", matcher.Regex.
ToString
());
194
Assert.Equal("^.*/ab.def$", matcher.Regex.
ToString
());
207
Assert.Equal("^.*/ab\\\\c$", matcher.Regex.
ToString
());
218
Assert.Equal("^.*/\\*.*\\*\\*[^/]*$", matcher.Regex.
ToString
());
230
Assert.Equal("^.*/\\?.\\?[^/]*\\?.$", matcher.Regex.
ToString
());
244
Assert.Equal(@"^.*/abc\{}def$", matcher.Regex.
ToString
());
256
Assert.Equal("^.*/abc,def$", matcher.Regex.
ToString
());
269
Assert.Equal("^.*/[^/]*\\.(?:cs|vb|fs)$", matcher.Regex.
ToString
());
299
Assert.Equal("^/(?:[^/]*\\.cs|subdir/test\\.vb)$", matcher.Regex.
ToString
());
313
Assert.Equal("^.*/(?:)$", matcher.Regex.
ToString
());
325
Assert.Equal("^.*/(?:[^/]*\\.cs)$", matcher.Regex.
ToString
());
351
Assert.Equal("^.*/(?:test(?:\\.cs|\\.vb)|other\\.(?:a(?:bb|cc)))$", matcher.Regex.
ToString
());
371
Assert.Equal("^.*/ab(?:-)cd(?:-|)ef$", matcher.Regex.
ToString
());
385
Assert.Equal("^.*/ab(?:cs|vb|fs)cd$", matcher.Regex.
ToString
());
505
Assert.Equal(@"^.*/[^/]*\.[cf]s$", matcher.Regex.
ToString
());
516
Assert.Equal(@"^.*/[^/]*\.[^cf]s$", matcher.Regex.
ToString
());
529
Assert.Equal(@"^.*/[^/]*\.[\^cf]s$", matcher.Regex.
ToString
());
543
Assert.Equal("^.*/[0-9]x$", matcher.Regex.
ToString
());
556
Assert.Equal("^.*/[^0-9]x$", matcher.Regex.
ToString
());
569
Assert.Equal("^.*/[ab0-9]x$", matcher.Regex.
ToString
());
614
Assert.Equal(@"^.*/[\[a]bc$", matcher.Regex.
ToString
());
629
Assert.Equal(@"^.*/[-ac]bd$", matcher.Regex.
ToString
());
644
Assert.Equal(@"^.*/[ac-]bd$", matcher.Regex.
ToString
());
658
Assert.Equal(@"^.*/[ab]]cd$", matcher.Regex.
ToString
());
673
Assert.Equal(@"^.*/[ab\\]cd$", matcher.Regex.
ToString
());
686
Assert.Equal(@"^.*/ab\[cd$", matcher.Regex.
ToString
());
Microsoft.Build.Engine.UnitTests (1)
BackEnd\SdkResolverLoader_Tests.cs (1)
263
resolversManifestsFound.First().ResolvableSdkRegex.
ToString
().ShouldBe("1<.*");
Microsoft.CodeAnalysis.LanguageServer.Protocol (1)
Protocol\Internal\Converters\RegexConverter.cs (1)
25
writer.WriteStringValue(value.
ToString
());
xunit.assert (2)
StringAsserts.cs (2)
573
var formattedExpected = AssertHelper.ShortenAndEncodeString(expectedRegex.
ToString
());
1385
throw MatchesException.ForMatchNotFound(expectedRegex.
ToString
(), actualString);