================
@@ -42,8 +43,19 @@ void clang::DiagnosticsTestHelper(DiagnosticsEngine &diag) {
namespace {
using testing::AllOf;
using testing::ElementsAre;
+using testing::HasSubstr;
using testing::IsEmpty;
+MATCHER_P(WithMessage, M,
+ "has diagnostic message that " +
+ ::testing::DescribeMatcher<std::string>(M)) {
+ return testing::ExplainMatchResult(M, arg.getMessage().str(),
+ result_listener);
+}
+MATCHER(IsError, "has error severity") {
----------------
jtstogel wrote:
Moved so that WithMessage is defined before use in
`reportAcceptsStringViewMessage`
https://github.com/llvm/llvm-project/pull/190374
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits