Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
yangql
googletest
Commits
c3748930
Commit
c3748930
authored
Feb 20, 2019
by
Gennadiy Civil
Browse files
Merge pull request #2123 from ngie-eign:clang-inconsistent-missing-override
PiperOrigin-RevId: 234840107
parents
873e4798
2147806d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
googlemock/test/gmock-matchers_test.cc
googlemock/test/gmock-matchers_test.cc
+3
-3
googletest/docs/primer.md
googletest/docs/primer.md
+1
-1
No files found.
googlemock/test/gmock-matchers_test.cc
View file @
c3748930
...
@@ -6943,10 +6943,10 @@ TEST(ArgsTest, ExplainsMatchResultWithoutInnerExplanation) {
...
@@ -6943,10 +6943,10 @@ TEST(ArgsTest, ExplainsMatchResultWithoutInnerExplanation) {
// For testing Args<>'s explanation.
// For testing Args<>'s explanation.
class
LessThanMatcher
:
public
MatcherInterface
<
std
::
tuple
<
char
,
int
>
>
{
class
LessThanMatcher
:
public
MatcherInterface
<
std
::
tuple
<
char
,
int
>
>
{
public:
public:
virtual
void
DescribeTo
(
::
std
::
ostream
*
os
)
const
{}
void
DescribeTo
(
::
std
::
ostream
*
os
)
const
override
{}
virtual
bool
MatchAndExplain
(
std
::
tuple
<
char
,
int
>
value
,
bool
MatchAndExplain
(
std
::
tuple
<
char
,
int
>
value
,
MatchResultListener
*
listener
)
const
{
MatchResultListener
*
listener
)
const
override
{
const
int
diff
=
std
::
get
<
0
>
(
value
)
-
std
::
get
<
1
>
(
value
);
const
int
diff
=
std
::
get
<
0
>
(
value
)
-
std
::
get
<
1
>
(
value
);
if
(
diff
>
0
)
{
if
(
diff
>
0
)
{
*
listener
<<
"where the first value is "
<<
diff
*
listener
<<
"where the first value is "
<<
diff
...
...
googletest/docs/primer.md
View file @
c3748930
...
@@ -122,7 +122,7 @@ To provide a custom failure message, simply stream it into the macro using the
...
@@ -122,7 +122,7 @@ To provide a custom failure message, simply stream it into the macro using the
```
c++
```
c++
ASSERT_EQ
(
x
.
size
(),
y
.
size
())
<<
"Vectors x and y are of unequal length"
;
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
;
EXPECT_EQ
(
x
[
i
],
y
[
i
])
<<
"Vectors x and y differ at index "
<<
i
;
}
}
```
```
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment