Merge pull request #2123 from ngie-eign:clang-inconsistent-missing-override
PiperOrigin-RevId: 234840107
This commit is contained in:
commit
c374893023
|
@ -6943,10 +6943,10 @@ TEST(ArgsTest, ExplainsMatchResultWithoutInnerExplanation) {
|
|||
// For testing Args<>'s explanation.
|
||||
class LessThanMatcher : public MatcherInterface<std::tuple<char, int> > {
|
||||
public:
|
||||
virtual void DescribeTo(::std::ostream* os) const {}
|
||||
void DescribeTo(::std::ostream* os) const override {}
|
||||
|
||||
virtual bool MatchAndExplain(std::tuple<char, int> value,
|
||||
MatchResultListener* listener) const {
|
||||
bool MatchAndExplain(std::tuple<char, int> value,
|
||||
MatchResultListener* listener) const override {
|
||||
const int diff = std::get<0>(value) - std::get<1>(value);
|
||||
if (diff > 0) {
|
||||
*listener << "where the first value is " << diff
|
||||
|
|
|
@ -122,7 +122,7 @@ To provide a custom failure message, simply stream it into the macro using the
|
|||
```c++
|
||||
ASSERT_EQ(x.size(), y.size()) << "Vectors x and y are of unequal length";
|
||||
|
||||
for (int i = 0; i < std::min(x.size(), y.size()); ++i) {
|
||||
for (int i = 0; i < x.size(); ++i) {
|
||||
EXPECT_EQ(x[i], y[i]) << "Vectors x and y differ at index " << i;
|
||||
}
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue
Block a user