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
2fe3bd99
Unverified
Commit
2fe3bd99
authored
Aug 31, 2018
by
Gennadiy Civil
Committed by
GitHub
Aug 31, 2018
Browse files
Merge pull request #1433 from dsacre/fix-clang-warnings
Fix Clang warnings
parents
4005388b
d615eebd
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
443 additions
and
23 deletions
+443
-23
googletest/include/gtest/gtest-param-test.h
googletest/include/gtest/gtest-param-test.h
+17
-20
googletest/include/gtest/gtest-typed-test.h
googletest/include/gtest/gtest-typed-test.h
+3
-2
googletest/include/gtest/gtest.h
googletest/include/gtest/gtest.h
+8
-0
googletest/include/gtest/internal/gtest-param-util-generated.h
...etest/include/gtest/internal/gtest-param-util-generated.h
+412
-0
googletest/include/gtest/internal/gtest-param-util-generated.h.pump
.../include/gtest/internal/gtest-param-util-generated.h.pump
+2
-0
googletest/src/gtest.cc
googletest/src/gtest.cc
+1
-1
No files found.
googletest/include/gtest/gtest-param-test.h
View file @
2fe3bd99
...
...
@@ -37,7 +37,6 @@
// This file is generated by a SCRIPT. DO NOT EDIT BY HAND!
//
// GOOGLETEST_CM0001 DO NOT DELETE
#ifndef GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_
#define GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_
...
...
@@ -1411,26 +1410,24 @@ internal::CartesianProductHolder10<Generator1, Generator2, Generator3,
// alphanumeric characters or underscore. Because PrintToString adds quotes
// to std::string and C strings, it won't work for these types.
#define INSTANTIATE_TEST_CASE_P(prefix, test_case_name, generator, ...) \
static ::testing::internal::ParamGenerator<test_case_name::ParamType> \
gtest_##prefix##test_case_name##_EvalGenerator_() { \
return generator; \
} \
static ::std::string gtest_##prefix##test_case_name##_EvalGenerateName_( \
const ::testing::TestParamInfo<test_case_name::ParamType>& info) { \
return ::testing::internal::GetParamNameGen<test_case_name::ParamType>( \
__VA_ARGS__)(info); \
} \
# define INSTANTIATE_TEST_CASE_P(prefix, test_case_name, generator, ...) \
static ::testing::internal::ParamGenerator<test_case_name::ParamType> \
gtest_##prefix##test_case_name##_EvalGenerator_() { return generator; } \
static ::std::string gtest_##prefix##test_case_name##_EvalGenerateName_( \
const ::testing::TestParamInfo<test_case_name::ParamType>& info) { \
return ::testing::internal::GetParamNameGen<test_case_name::ParamType> \
(__VA_ARGS__)(info); \
} \
static int gtest_##prefix##test_case_name##_dummy_ GTEST_ATTRIBUTE_UNUSED_ = \
::testing::UnitTest::GetInstance()
\
->parameterized_test_registry()
\
.GetTestCasePatternHolder<test_case_name>(
\
#
test
_case_name,
\
::testing::internal::CodeLocation(__FILE__, __LINE__))
\
->AddTestCaseInstantiation(
\
#prefix,
>est_##prefix##test_case_name##_EvalGenerator_,
\
>est_##prefix##test_case_name##_EvalGenerateName_,
__FILE__,
\
__LINE__)
::testing::UnitTest::GetInstance()
->parameterized_test_registry().
\
GetTestCasePatternHolder<test_case_name>(
\
#test_case_name,
\
::
test
ing::internal::CodeLocation(
\
__FILE__, __LINE__))->AddTestCaseInstantiation(
\
#prefix,
\
>est_##prefix##test_case_name##_EvalGenerator_, \
>est_##prefix##test_case_name##_EvalGenerateName_, \
__FILE__,
__LINE__)
}
// namespace testing
...
...
googletest/include/gtest/gtest-typed-test.h
View file @
2fe3bd99
...
...
@@ -206,7 +206,8 @@ INSTANTIATE_TYPED_TEST_CASE_P(My, FooTest, MyTypes);
typedef gtest_TypeParam_ TypeParam; \
virtual void TestBody(); \
}; \
bool gtest_##CaseName##_##TestName##_registered_ GTEST_ATTRIBUTE_UNUSED_ = \
static bool gtest_##CaseName##_##TestName##_registered_ \
GTEST_ATTRIBUTE_UNUSED_ = \
::testing::internal::TypeParameterizedTest< \
CaseName, \
::testing::internal::TemplateSel<GTEST_TEST_CLASS_NAME_(CaseName, \
...
...
@@ -287,7 +288,7 @@ INSTANTIATE_TYPED_TEST_CASE_P(My, FooTest, MyTypes);
// since some compilers may choke on '>>' when passing a template
// instance (e.g. Types<int>)
# define INSTANTIATE_TYPED_TEST_CASE_P(Prefix, CaseName, Types, ...) \
bool gtest_##Prefix##_##CaseName GTEST_ATTRIBUTE_UNUSED_ =
\
static
bool gtest_##Prefix##_##CaseName GTEST_ATTRIBUTE_UNUSED_ = \
::testing::internal::TypeParameterizedTestCase< \
CaseName, GTEST_CASE_NAMESPACE_(CaseName)::gtest_AllTests_, \
::testing::internal::TypeList< Types >::type>:: \
...
...
googletest/include/gtest/gtest.h
View file @
2fe3bd99
...
...
@@ -116,6 +116,10 @@ GTEST_DECLARE_string_(color);
// the tests to run. If the filter is not given all tests are executed.
GTEST_DECLARE_string_
(
filter
);
// This flag controls whether Google Test installs a signal handler that dumps
// debugging information when fatal signals are raised.
GTEST_DECLARE_bool_
(
install_failure_signal_handler
);
// This flag causes the Google Test to list tests. None of the tests listed
// are actually run if the flag is provided.
GTEST_DECLARE_bool_
(
list_tests
);
...
...
@@ -159,6 +163,10 @@ GTEST_DECLARE_bool_(throw_on_failure);
// the specified host machine.
GTEST_DECLARE_string_
(
stream_result_to
);
#if GTEST_USE_OWN_FLAGFILE_FLAG_
GTEST_DECLARE_string_
(
flagfile
);
#endif // GTEST_USE_OWN_FLAGFILE_FLAG_
// The upper limit for valid stack trace depths.
const
int
kMaxStackTraceDepth
=
100
;
...
...
googletest/include/gtest/internal/gtest-param-util-generated.h
View file @
2fe3bd99
This diff is collapsed.
Click to expand it.
googletest/include/gtest/internal/gtest-param-util-generated.h.pump
View file @
2fe3bd99
...
...
@@ -83,6 +83,8 @@ class ValueArray$i {
return
ValuesIn
(
array
);
}
ValueArray
$
i
(
const
ValueArray
$
i
&
other
)
:
$
for
j
,
[[
v
$
(
j
)
_
(
other
.
v
$
(
j
)
_
)]]
{}
private:
// No implementation - assignment is unsupported.
void
operator
=
(
const
ValueArray
$
i
&
other
);
...
...
googletest/src/gtest.cc
View file @
2fe3bd99
...
...
@@ -427,7 +427,7 @@ void AssertHelper::operator=(const Message& message) const {
GTEST_API_
GTEST_DEFINE_STATIC_MUTEX_
(
g_linked_ptr_mutex
);
// A copy of all command line arguments. Set by InitGoogleTest().
::
std
::
vector
<
std
::
string
>
g_argvs
;
static
::
std
::
vector
<
std
::
string
>
g_argvs
;
::
std
::
vector
<
std
::
string
>
GetArgvs
()
{
#if defined(GTEST_CUSTOM_GET_ARGVS_)
...
...
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