| 196 | {} |
| 197 | |
| 198 | bool MatchAndExplain(const MapValue& arg, |
| 199 | testing::MatchResultListener* result_listener) const { |
| 200 | std::vector<std::pair<Value, Value>> elements; |
| 201 | absl::Status s = arg.ForEach( |
| 202 | [&](const Value& key, const Value& value) -> absl::StatusOr<bool> { |
| 203 | elements.push_back({key, value}); |
| 204 | return true; |
| 205 | }, |
| 206 | descriptor_pool_, message_factory_, arena_); |
| 207 | if (!s.ok()) { |
| 208 | *result_listener << "cannot convert to list of values: " << s; |
| 209 | return false; |
| 210 | } |
| 211 | return m_.MatchAndExplain(elements, result_listener); |
| 212 | } |
| 213 | |
| 214 | void DescribeTo(std::ostream* os) const { *os << m_; } |
| 215 | void DescribeNegationTo(std::ostream* os) const { *os << m_; } |
no test coverage detected