aboutsummaryrefslogtreecommitdiffstats
path: root/googletest/include
diff options
context:
space:
mode:
authorShahbaz Youssefi <syoussefi@google.com>2019-12-10 09:59:56 -0500
committerShahbaz Youssefi <syoussefi@chromium.org>2019-12-16 13:01:52 -0500
commit4b7809c2f5236b16a2e3b45e2b5ade48fb6a3c0c (patch)
tree12c43c326e613a4d8e96fe1399521f54ae69576f /googletest/include
parentd2016469064bdb488ce271c84684518d2716fec2 (diff)
downloadgoogletest-4b7809c2f5236b16a2e3b45e2b5ade48fb6a3c0c.tar.gz
googletest-4b7809c2f5236b16a2e3b45e2b5ade48fb6a3c0c.tar.bz2
googletest-4b7809c2f5236b16a2e3b45e2b5ade48fb6a3c0c.zip
Revert "Googletest export": Remove test for empty prefix
This reverts commit 4c25e2b87fcb78abcfdee2739db9ed7a19754cd3. Reason for revert: Reverting the commit that disallows empty prefixes. Original commit message: Remove a test case rendered obsolete by disallowing empty argument for INSTANTIATE_TEST_SUITE_P. Remove the code that it was testing.
Diffstat (limited to 'googletest/include')
-rw-r--r--googletest/include/gtest/internal/gtest-param-util.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/googletest/include/gtest/internal/gtest-param-util.h b/googletest/include/gtest/internal/gtest-param-util.h
index 70c43354..3f2495bf 100644
--- a/googletest/include/gtest/internal/gtest-param-util.h
+++ b/googletest/include/gtest/internal/gtest-param-util.h
@@ -574,7 +574,10 @@ class ParameterizedTestSuiteInfo : public ParameterizedTestSuiteInfoBase {
test_param_names.insert(param_name);
- test_name_stream << test_info->test_base_name << "/" << param_name;
+ if (!test_info->test_base_name.empty()) {
+ test_name_stream << test_info->test_base_name << "/";
+ }
+ test_name_stream << param_name;
MakeAndRegisterTestInfo(
test_suite_name.c_str(), test_name_stream.GetString().c_str(),
nullptr, // No type parameter.