Regexpf asserts that a specified regexp matches a string. assert.Regexpf(t, regexp.MustCompile("start"), "it's starting", "error message %s", "formatted") assert.Regexpf(t, "start...$", "it's not starting", "error message %s", "formatted")
(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{})
| 784 | // assert.Regexpf(t, regexp.MustCompile("start"), "it's starting", "error message %s", "formatted") |
| 785 | // assert.Regexpf(t, "start...$", "it's not starting", "error message %s", "formatted") |
| 786 | func Regexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{}) bool { |
| 787 | if h, ok := t.(tHelper); ok { |
| 788 | h.Helper() |
| 789 | } |
| 790 | return Regexp(t, rx, str, append([]interface{}{msg}, args...)...) |
| 791 | } |
| 792 | |
| 793 | // Samef asserts that two pointers reference the same object. |
| 794 | // |