testify
testify copied to clipboard
assert.Regexp: Document allowed rx argument values #268
Reference: https://github.com/Antonboom/testifylint/issues/81#issuecomment-3290922001
The Regexp and NotRegexp assertion accept interface{} for the rx (expression) argument. This is insane but we can't change it because it would be a breaking change. The documentation for these functions should be changed to explain that the value should be a *regexp.Regexp, but that if any other type is provided then the %v format of the value will be compiled as a new expression.