Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
yangql
googletest
Commits
c33ce7c1
Commit
c33ce7c1
authored
Jul 27, 2015
by
kosak
Browse files
Inject the custom InitGoogleTest function using a macro.
parent
f487e951
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
src/gtest.cc
src/gtest.cc
+8
-0
No files found.
src/gtest.cc
View file @
c33ce7c1
...
...
@@ -5361,13 +5361,21 @@ void InitGoogleTestImpl(int* argc, CharType** argv) {
//
// Calling the function for the second time has no user-visible effect.
void
InitGoogleTest
(
int
*
argc
,
char
**
argv
)
{
#if defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_
(
argc
,
argv
);
#else // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
internal
::
InitGoogleTestImpl
(
argc
,
argv
);
#endif // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
}
// This overloaded version can be used in Windows programs compiled in
// UNICODE mode.
void
InitGoogleTest
(
int
*
argc
,
wchar_t
**
argv
)
{
#if defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_
(
argc
,
argv
);
#else // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
internal
::
InitGoogleTestImpl
(
argc
,
argv
);
#endif // defined(GTEST_CUSTOM_INIT_GOOGLE_TEST_FUNCTION_)
}
}
// namespace testing
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