Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
googletest
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
googletest
Commits
a651a4d4
Commit
a651a4d4
authored
Oct 12, 2018
by
Gennadiy Civil
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1908 from rwoldberg:master
PiperOrigin-RevId: 216909845
parents
864b6c2d
dec3b81a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
gmock-spec-builders.h
googlemock/include/gmock/gmock-spec-builders.h
+6
-5
No files found.
googlemock/include/gmock/gmock-spec-builders.h
View file @
a651a4d4
...
@@ -1184,9 +1184,10 @@ class TypedExpectation : public ExpectationBase {
...
@@ -1184,9 +1184,10 @@ class TypedExpectation : public ExpectationBase {
Log
(
kWarning
,
ss
.
str
(),
1
);
Log
(
kWarning
,
ss
.
str
(),
1
);
}
}
return
count
<=
action_count
?
return
count
<=
action_count
*
static_cast
<
const
Action
<
F
>*>
(
untyped_actions_
[
count
-
1
])
:
?
*
static_cast
<
const
Action
<
F
>*>
(
repeated_action
();
untyped_actions_
[
static_cast
<
size_t
>
(
count
-
1
)])
:
repeated_action
();
}
}
// Given the arguments of a mock function call, if the call will
// Given the arguments of a mock function call, if the call will
...
@@ -1762,12 +1763,12 @@ class FunctionMockerBase : public UntypedFunctionMockerBase {
...
@@ -1762,12 +1763,12 @@ class FunctionMockerBase : public UntypedFunctionMockerBase {
::
std
::
ostream
*
why
)
const
::
std
::
ostream
*
why
)
const
GTEST_EXCLUSIVE_LOCK_REQUIRED_
(
g_gmock_mutex
)
{
GTEST_EXCLUSIVE_LOCK_REQUIRED_
(
g_gmock_mutex
)
{
g_gmock_mutex
.
AssertHeld
();
g_gmock_mutex
.
AssertHeld
();
const
int
count
=
static_cast
<
int
>
(
untyped_expectations_
.
size
()
);
const
size_t
count
=
untyped_expectations_
.
size
(
);
*
why
<<
"Google Mock tried the following "
<<
count
<<
" "
*
why
<<
"Google Mock tried the following "
<<
count
<<
" "
<<
(
count
==
1
?
"expectation, but it didn't match"
:
<<
(
count
==
1
?
"expectation, but it didn't match"
:
"expectations, but none matched"
)
"expectations, but none matched"
)
<<
":
\n
"
;
<<
":
\n
"
;
for
(
in
t
i
=
0
;
i
<
count
;
i
++
)
{
for
(
size_
t
i
=
0
;
i
<
count
;
i
++
)
{
TypedExpectation
<
F
>*
const
expectation
=
TypedExpectation
<
F
>*
const
expectation
=
static_cast
<
TypedExpectation
<
F
>*>
(
untyped_expectations_
[
i
].
get
());
static_cast
<
TypedExpectation
<
F
>*>
(
untyped_expectations_
[
i
].
get
());
*
why
<<
"
\n
"
;
*
why
<<
"
\n
"
;
...
...
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