6 references to Matches
ConfigurationSchemaGenerator.Tests (1)
GeneratorTests.cs (1)
1366
Assert.
Matches
(TimeSpanRegex(), validTimeSpanString);
Microsoft.DotNet.XUnitAssert.Tests (5)
StringAssertsTests.cs (5)
784
Assert.Throws<ArgumentNullException>("expectedRegex", () => Assert.
Matches
((Regex?)null!, "Hello, world!"));
790
Assert.
Matches
(new Regex(@"\w+"), "Hello");
796
Assert.
Matches
(new Regex(@"[a-z]+", RegexOptions.IgnoreCase), "HELLO");
802
var ex = Record.Exception(() => Assert.
Matches
(new Regex(@"\d+"), "Hello, world!"));
816
var ex = Record.Exception(() => Assert.
Matches
(new Regex(@"\d+"), null));