diff options
author | Francesco Guastella <francesco.guastella@bisimulations.com> | 2021-12-20 17:35:09 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-01-07 14:25:57 (GMT) |
commit | 1f9554d4e95087a63b3ab8279cfbda6c3b25004d (patch) | |
tree | edebf6852b6b9a3bc82354167f38b0d6667e7c17 /Tests | |
parent | 353318cc53b87f647141e8d12e79bd4b20be489b (diff) | |
download | CMake-1f9554d4e95087a63b3ab8279cfbda6c3b25004d.zip CMake-1f9554d4e95087a63b3ab8279cfbda6c3b25004d.tar.gz CMake-1f9554d4e95087a63b3ab8279cfbda6c3b25004d.tar.bz2 |
GoogleTest: Fix regex matching all dots in the suite name
Diffstat (limited to 'Tests')
8 files changed, 170 insertions, 89 deletions
diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-basic-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-basic-stdout.txt index 385159d..5d358ce 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-basic-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-basic-stdout.txt @@ -3,5 +3,9 @@ Test project .*/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change Test #2: basic\.case_bar Test #3: basic\.disabled_case \(Disabled\) Test #4: basic\.DISABLEDnot_really_case + Test #5: ns\.basic\.case_foo + Test #6: ns\.basic\.case_bar + Test #7: ns\.basic\.disabled_case \(Disabled\) + Test #8: ns\.basic\.DISABLEDnot_really_case -Total Tests: 4 +Total Tests: 8 diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-typed-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-typed-stdout.txt index 095fdcd..fe8f273 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-typed-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change-typed-stdout.txt @@ -1,5 +1,7 @@ Test project .*/Tests/RunCMake/GoogleTest/GoogleTest-discovery-arg-change Test #1: typed/short\.case Test #2: typed/float\.case + Test #3: ns\.typed/short\.case + Test #4: ns\.typed/float\.case -Total Tests: 2 +Total Tests: 4 diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-skip-test-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-skip-test-stdout.txt index d06cd0a..58b2453 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-skip-test-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-skip-test-stdout.txt @@ -1,10 +1,10 @@ Test project .* - Start 36: skip_test.test1 -1/1 Test #36: skip_test.test1 \.+\*\*\*Skipped +[0-9.]+ sec + Start 64: skip_test\.test1 +1/1 Test #64: skip_test\.test1 \.+\*\*\*Skipped +[0-9.]+ sec 100% tests passed, 0 tests failed out of 1 Total Test time \(real\) = +[0-9.]+ sec The following tests did not run: -.*36 - skip_test\.test1 \(Skipped\) +.*64 - skip_test\.test1 \(Skipped\) diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-test1-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-test1-stdout.txt index 2a53c5b..bf98a66 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-test1-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-test1-stdout.txt @@ -1,35 +1,58 @@ Test project .* Start 1: TEST:basic\.case_foo!1 - 1/13 Test #1: TEST:basic\.case_foo!1 \.+ +Passed +[0-9.]+ sec + 1/24 Test #1: TEST:basic\.case_foo!1 \.+ +Passed +[0-9.]+ sec Start 2: TEST:basic\.case_bar!1 - 2/13 Test #2: TEST:basic\.case_bar!1 \.+ +Passed +[0-9.]+ sec + 2/24 Test #2: TEST:basic\.case_bar!1 \.+ +Passed +[0-9.]+ sec Start 3: TEST:basic\.disabled_case!1 - 3/13 Test #3: TEST:basic\.disabled_case!1 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + 3/24 Test #3: TEST:basic\.disabled_case!1 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec Start 4: TEST:basic\.DISABLEDnot_really_case!1 - 4/13 Test #4: TEST:basic\.DISABLEDnot_really_case!1 \.+ +Passed +[0-9.]+ sec - Start 5: TEST:disabled\.case!1 - 5/13 Test #5: TEST:disabled\.case!1 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec - Start 6: TEST:DISABLEDnotreally\.case!1 - 6/13 Test #6: TEST:DISABLEDnotreally\.case!1 \.+ +Passed +[0-9.]+ sec - Start 7: TEST:typed/short\.case!1 - 7/13 Test #7: TEST:typed/short\.case!1 \.+ +Passed +[0-9.]+ sec - Start 8: TEST:typed/float\.case!1 - 8/13 Test #8: TEST:typed/float\.case!1 \.+ +Passed +[0-9.]+ sec - Start 9: TEST:value/test\.case/1!1 - 9/13 Test #9: TEST:value/test\.case/1!1 \.+ +Passed +[0-9.]+ sec - Start 10: TEST:value/test\.case/"foo"!1 -10/13 Test #10: TEST:value/test\.case/"foo"!1 \.+ +Passed +[0-9.]+ sec - Start 11: TEST:param/special\.case/"semicolon;"!1 -11/13 Test #11: TEST:param/special\.case/"semicolon;"!1 \.+ +Passed +[0-9.]+ sec - Start 12: TEST:param/special\.case/"backslash\\"!1 -12/13 Test #12: TEST:param/special\.case/"backslash\\"!1 \.+ +Passed +[0-9.]+ sec - Start 13: TEST:param/special\.case/"\$\{var\}"!1 -13/13 Test #13: TEST:param/special\.case/"\$\{var\}"!1 \.+ +Passed +[0-9.]+ sec + 4/24 Test #4: TEST:basic\.DISABLEDnot_really_case!1 \.+ +Passed +[0-9.]+ sec + Start 5: TEST:ns\.basic\.case_foo!1 + 5/24 Test #5: TEST:ns\.basic\.case_foo!1 \.+ +Passed +[0-9.]+ sec + Start 6: TEST:ns\.basic\.case_bar!1 + 6/24 Test #6: TEST:ns\.basic\.case_bar!1 \.+ +Passed +[0-9.]+ sec + Start 7: TEST:ns\.basic\.disabled_case!1 + 7/24 Test #7: TEST:ns\.basic\.disabled_case!1 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 8: TEST:ns\.basic\.DISABLEDnot_really_case!1 + 8/24 Test #8: TEST:ns\.basic\.DISABLEDnot_really_case!1 \.+ +Passed +[0-9.]+ sec + Start 9: TEST:disabled\.case!1 + 9/24 Test #9: TEST:disabled\.case!1 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 10: TEST:DISABLEDnotreally\.case!1 +10/24 Test #10: TEST:DISABLEDnotreally\.case!1 \.+ +Passed +[0-9.]+ sec + Start 11: TEST:typed/short\.case!1 +11/24 Test #11: TEST:typed/short\.case!1 \.+ +Passed +[0-9.]+ sec + Start 12: TEST:typed/float\.case!1 +12/24 Test #12: TEST:typed/float\.case!1 \.+ +Passed +[0-9.]+ sec + Start 13: TEST:ns\.typed/short\.case!1 +13/24 Test #13: TEST:ns\.typed/short\.case!1 \.+ +Passed +[0-9.]+ sec + Start 14: TEST:ns\.typed/float\.case!1 +14/24 Test #14: TEST:ns\.typed/float\.case!1 \.+ +Passed +[0-9.]+ sec + Start 15: TEST:value/test\.case/1!1 +15/24 Test #15: TEST:value/test\.case/1!1 \.+ +Passed +[0-9.]+ sec + Start 16: TEST:value/test\.case/"foo"!1 +16/24 Test #16: TEST:value/test\.case/"foo"!1 \.+ +Passed +[0-9.]+ sec + Start 17: TEST:ns\.value/test\.case/1!1 +17/24 Test #17: TEST:ns\.value/test\.case/1!1 \.+ +Passed +[0-9.]+ sec + Start 18: TEST:ns\.value/test\.case/"foo"!1 +18/24 Test #18: TEST:ns\.value/test\.case/"foo"!1 \.+ +Passed +[0-9.]+ sec + Start 19: TEST:param/special\.case/"semicolon;"!1 +19/24 Test #19: TEST:param/special\.case/"semicolon;"!1 \.+ +Passed +[0-9.]+ sec + Start 20: TEST:param/special\.case/"backslash\\"!1 +20/24 Test #20: TEST:param/special\.case/"backslash\\"!1 \.+ +Passed +[0-9.]+ sec + Start 21: TEST:param/special\.case/"\${var}"!1 +21/24 Test #21: TEST:param/special\.case/"\${var}"!1 \.+ +Passed +[0-9.]+ sec + Start 22: TEST:ns\.param/special\.case/"semicolon;"!1 +22/24 Test #22: TEST:ns\.param/special\.case/"semicolon;"!1 \.+ +Passed +[0-9.]+ sec + Start 23: TEST:ns\.param/special\.case/"backslash\\"!1 +23/24 Test #23: TEST:ns\.param/special\.case/"backslash\\"!1 \.+ +Passed +[0-9.]+ sec + Start 24: TEST:ns\.param/special\.case/"\${var}"!1 +24/24 Test #24: TEST:ns\.param/special\.case/"\${var}"!1 \.+ +Passed +[0-9.]+ sec -100% tests passed, 0 tests failed out of 11 +100% tests passed, 0 tests failed out of 21 Total Test time \(real\) = +[0-9.]+ sec The following tests did not run: .*3 - TEST:basic\.disabled_case!1 \(Disabled\) -.*5 - TEST:disabled\.case!1 \(Disabled\) +.*7 - TEST:ns\.basic\.disabled_case!1 \(Disabled\) +.*9 - TEST:disabled\.case!1 \(Disabled\) diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-test2-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-test2-stdout.txt index 5b68e10..089e3e8 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-test2-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-test2-stdout.txt @@ -1,35 +1,58 @@ Test project .* - Start 14: TEST:basic\.case_foo!2 - 1/13 Test #14: TEST:basic\.case_foo!2 \.+ +Passed +[0-9.]+ sec - Start 15: TEST:basic\.case_bar!2 - 2/13 Test #15: TEST:basic\.case_bar!2 \.+ +Passed +[0-9.]+ sec - Start 16: TEST:basic\.disabled_case!2 - 3/13 Test #16: TEST:basic\.disabled_case!2 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec - Start 17: TEST:basic\.DISABLEDnot_really_case!2 - 4/13 Test #17: TEST:basic\.DISABLEDnot_really_case!2 \.+ +Passed +[0-9.]+ sec - Start 18: TEST:disabled\.case!2 - 5/13 Test #18: TEST:disabled\.case!2 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec - Start 19: TEST:DISABLEDnotreally\.case!2 - 6/13 Test #19: TEST:DISABLEDnotreally\.case!2 \.+ +Passed +[0-9.]+ sec - Start 20: TEST:typed/short\.case!2 - 7/13 Test #20: TEST:typed/short\.case!2 \.+ +Passed +[0-9.]+ sec - Start 21: TEST:typed/float\.case!2 - 8/13 Test #21: TEST:typed/float\.case!2 \.+ +Passed +[0-9.]+ sec - Start 22: TEST:value/test\.case/1!2 - 9/13 Test #22: TEST:value/test\.case/1!2 \.+ +Passed +[0-9.]+ sec - Start 23: TEST:value/test\.case/"foo"!2 -10/13 Test #23: TEST:value/test\.case/"foo"!2 \.+ +Passed +[0-9.]+ sec - Start 24: TEST:param/special\.case/"semicolon;"!2 -11/13 Test #24: TEST:param/special\.case/"semicolon;"!2 \.+ +Passed +[0-9.]+ sec - Start 25: TEST:param/special\.case/"backslash\\"!2 -12/13 Test #25: TEST:param/special\.case/"backslash\\"!2 \.+ +Passed +[0-9.]+ sec - Start 26: TEST:param/special\.case/"\$\{var\}"!2 -13/13 Test #26: TEST:param/special\.case/"\$\{var\}"!2 \.+ +Passed +[0-9.]+ sec + Start 25: TEST:basic\.case_foo!2 + 1/24 Test #25: TEST:basic\.case_foo!2 \.+ +Passed +[0-9.]+ sec + Start 26: TEST:basic\.case_bar!2 + 2/24 Test #26: TEST:basic\.case_bar!2 \.+ +Passed +[0-9.]+ sec + Start 27: TEST:basic\.disabled_case!2 + 3/24 Test #27: TEST:basic\.disabled_case!2 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 28: TEST:basic\.DISABLEDnot_really_case!2 + 4/24 Test #28: TEST:basic\.DISABLEDnot_really_case!2 \.+ +Passed +[0-9.]+ sec + Start 29: TEST:ns\.basic\.case_foo!2 + 5/24 Test #29: TEST:ns\.basic\.case_foo!2 \.+ +Passed +[0-9.]+ sec + Start 30: TEST:ns\.basic\.case_bar!2 + 6/24 Test #30: TEST:ns\.basic\.case_bar!2 \.+ +Passed +[0-9.]+ sec + Start 31: TEST:ns\.basic\.disabled_case!2 + 7/24 Test #31: TEST:ns\.basic\.disabled_case!2 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 32: TEST:ns\.basic\.DISABLEDnot_really_case!2 + 8/24 Test #32: TEST:ns\.basic\.DISABLEDnot_really_case!2 \.+ +Passed +[0-9.]+ sec + Start 33: TEST:disabled\.case!2 + 9/24 Test #33: TEST:disabled\.case!2 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 34: TEST:DISABLEDnotreally\.case!2 +10/24 Test #34: TEST:DISABLEDnotreally\.case!2 \.+ +Passed +[0-9.]+ sec + Start 35: TEST:typed/short\.case!2 +11/24 Test #35: TEST:typed/short\.case!2 \.+ +Passed +[0-9.]+ sec + Start 36: TEST:typed/float\.case!2 +12/24 Test #36: TEST:typed/float\.case!2 \.+ +Passed +[0-9.]+ sec + Start 37: TEST:ns\.typed/short\.case!2 +13/24 Test #37: TEST:ns\.typed/short\.case!2 \.+ +Passed +[0-9.]+ sec + Start 38: TEST:ns\.typed/float\.case!2 +14/24 Test #38: TEST:ns\.typed/float\.case!2 \.+ +Passed +[0-9.]+ sec + Start 39: TEST:value/test\.case/1!2 +15/24 Test #39: TEST:value/test\.case/1!2 \.+ +Passed +[0-9.]+ sec + Start 40: TEST:value/test\.case/"foo"!2 +16/24 Test #40: TEST:value/test\.case/"foo"!2 \.+ +Passed +[0-9.]+ sec + Start 41: TEST:ns\.value/test\.case/1!2 +17/24 Test #41: TEST:ns\.value/test\.case/1!2 \.+ +Passed +[0-9.]+ sec + Start 42: TEST:ns\.value/test\.case/"foo"!2 +18/24 Test #42: TEST:ns\.value/test\.case/"foo"!2 \.+ +Passed +[0-9.]+ sec + Start 43: TEST:param/special\.case/"semicolon;"!2 +19/24 Test #43: TEST:param/special\.case/"semicolon;"!2 \.+ +Passed +[0-9.]+ sec + Start 44: TEST:param/special\.case/"backslash\\"!2 +20/24 Test #44: TEST:param/special\.case/"backslash\\"!2 \.+ +Passed +[0-9.]+ sec + Start 45: TEST:param/special\.case/"\${var}"!2 +21/24 Test #45: TEST:param/special\.case/"\${var}"!2 \.+ +Passed +[0-9.]+ sec + Start 46: TEST:ns\.param/special\.case/"semicolon;"!2 +22/24 Test #46: TEST:ns\.param/special\.case/"semicolon;"!2 \.+ +Passed +[0-9.]+ sec + Start 47: TEST:ns\.param/special\.case/"backslash\\"!2 +23/24 Test #47: TEST:ns\.param/special\.case/"backslash\\"!2 \.+ +Passed +[0-9.]+ sec + Start 48: TEST:ns\.param/special\.case/"\${var}"!2 +24/24 Test #48: TEST:ns\.param/special\.case/"\${var}"!2 \.+ +Passed +[0-9.]+ sec -100% tests passed, 0 tests failed out of 11 +100% tests passed, 0 tests failed out of 21 Total Test time \(real\) = +[0-9.]+ sec The following tests did not run: -.*16 - TEST:basic\.disabled_case!2 \(Disabled\) -.*18 - TEST:disabled\.case!2 \(Disabled\) +.*27 - TEST:basic\.disabled_case!2 \(Disabled\) +.*31 - TEST:ns\.basic\.disabled_case!2 \(Disabled\) +.*33 - TEST:disabled\.case!2 \(Disabled\) diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-test3-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-test3-stdout.txt index cf08267..3593dfe 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-test3-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-test3-stdout.txt @@ -1,16 +1,25 @@ Test project .* - Start 27: TEST:basic\.case_foo!3 -1/4 Test #27: TEST:basic\.case_foo!3 \.+ +Passed +[0-9.]+ sec - Start 28: TEST:basic\.case_bar!3 -2/4 Test #28: TEST:basic\.case_bar!3 \.+ +Passed +[0-9.]+ sec - Start 29: TEST:basic\.disabled_case!3 -3/4 Test #29: TEST:basic\.disabled_case!3 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec - Start 30: TEST:basic\.DISABLEDnot_really_case!3 -4/4 Test #30: TEST:basic\.DISABLEDnot_really_case!3 \.+ +Passed +[0-9.]+ sec + Start 49: TEST:basic\.case_foo!3 +1/8 Test #49: TEST:basic\.case_foo!3 \.+ +Passed +[0-9.]+ sec + Start 50: TEST:basic\.case_bar!3 +2/8 Test #50: TEST:basic\.case_bar!3 \.+ +Passed +[0-9.]+ sec + Start 51: TEST:basic\.disabled_case!3 +3/8 Test #51: TEST:basic\.disabled_case!3 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 52: TEST:basic\.DISABLEDnot_really_case!3 +4/8 Test #52: TEST:basic\.DISABLEDnot_really_case!3 \.+ +Passed +[0-9.]+ sec + Start 53: TEST:ns\.basic\.case_foo!3 +5/8 Test #53: TEST:ns\.basic\.case_foo!3 \.+ +Passed +[0-9.]+ sec + Start 54: TEST:ns\.basic\.case_bar!3 +6/8 Test #54: TEST:ns\.basic\.case_bar!3 \.+ +Passed +[0-9.]+ sec + Start 55: TEST:ns\.basic\.disabled_case!3 +7/8 Test #55: TEST:ns\.basic\.disabled_case!3 \.+\*+Not Run \(Disabled\) +[0-9.]+ sec + Start 56: TEST:ns\.basic\.DISABLEDnot_really_case!3 +8/8 Test #56: TEST:ns\.basic\.DISABLEDnot_really_case!3 \.+ +Passed +[0-9.]+ sec -100% tests passed, 0 tests failed out of 3 +100% tests passed, 0 tests failed out of 6 Total Test time \(real\) = +[0-9.]+ sec The following tests did not run: -.*29 - TEST:basic.disabled_case!3 \(Disabled\) +.*51 - TEST:basic\.disabled_case!3 \(Disabled\) +.*55 - TEST:ns\.basic\.disabled_case!3 \(Disabled\) diff --git a/Tests/RunCMake/GoogleTest/GoogleTest-test4-stdout.txt b/Tests/RunCMake/GoogleTest/GoogleTest-test4-stdout.txt index 4a9d75b..c40be9e 100644 --- a/Tests/RunCMake/GoogleTest/GoogleTest-test4-stdout.txt +++ b/Tests/RunCMake/GoogleTest/GoogleTest-test4-stdout.txt @@ -1,9 +1,13 @@ Test project .* - Start 31: TEST:typed/short\.case!4 -1/2 Test #31: TEST:typed/short\.case!4 \.+ +Passed +[0-9.]+ sec - Start 32: TEST:typed/float\.case!4 -2/2 Test #32: TEST:typed/float\.case!4 \.+ +Passed +[0-9.]+ sec + Start 57: TEST:typed/short\.case!4 +1/4 Test #57: TEST:typed/short\.case!4 \.+ +Passed +[0-9.]+ sec + Start 58: TEST:typed/float\.case!4 +2/4 Test #58: TEST:typed/float\.case!4 \.+ +Passed +[0-9.]+ sec + Start 59: TEST:ns\.typed/short\.case!4 +3/4 Test #59: TEST:ns\.typed/short\.case!4 \.+ +Passed +[0-9.]+ sec + Start 60: TEST:ns\.typed/float\.case!4 +4/4 Test #60: TEST:ns\.typed/float\.case!4 \.+ +Passed +[0-9.]+ sec -100% tests passed, 0 tests failed out of 2 +100% tests passed, 0 tests failed out of 4 Total Test time \(real\) = +[0-9.]+ sec diff --git a/Tests/RunCMake/GoogleTest/fake_gtest.cpp b/Tests/RunCMake/GoogleTest/fake_gtest.cpp index b2a5cb4..36f1d3c 100644 --- a/Tests/RunCMake/GoogleTest/fake_gtest.cpp +++ b/Tests/RunCMake/GoogleTest/fake_gtest.cpp @@ -1,6 +1,8 @@ #include <iostream> #include <string> +#define ARRAY_SIZE(a) sizeof(a) / sizeof(*a) + int main(int argc, char** argv) { // Note: GoogleTest.cmake doesn't actually depend on Google Test as such; @@ -16,11 +18,14 @@ int main(int argc, char** argv) if (argc > 1 && std::string(argv[1]) == "--gtest_list_tests") { if (!is_typed_only) { - std::cout << "basic." << std::endl; - std::cout << " case_foo" << std::endl; - std::cout << " case_bar" << std::endl; - std::cout << " DISABLED_disabled_case" << std::endl; - std::cout << " DISABLEDnot_really_case" << std::endl; + const char* basic_suite_names[] = { "basic.", "ns.basic." }; + for (size_t i = 0; i < ARRAY_SIZE(basic_suite_names); i++) { + std::cout << basic_suite_names[i] << std::endl; + std::cout << " case_foo" << std::endl; + std::cout << " case_bar" << std::endl; + std::cout << " DISABLED_disabled_case" << std::endl; + std::cout << " DISABLEDnot_really_case" << std::endl; + } } if (!is_basic_only && !is_typed_only) { std::cout << "DISABLED_disabled." << std::endl; @@ -29,19 +34,30 @@ int main(int argc, char** argv) std::cout << " case" << std::endl; } if (!is_basic_only) { - std::cout << "typed/0. # TypeParam = short" << std::endl; - std::cout << " case" << std::endl; - std::cout << "typed/1. # TypeParam = float" << std::endl; - std::cout << " case" << std::endl; + const char* typed_suite_names[] = { "typed", "ns.typed" }; + for (size_t i = 0; i < ARRAY_SIZE(typed_suite_names); i++) { + std::cout << typed_suite_names[i] << "/0. # TypeParam = short" + << std::endl; + std::cout << " case" << std::endl; + std::cout << typed_suite_names[i] << "/1. # TypeParam = float" + << std::endl; + std::cout << " case" << std::endl; + } } if (!is_basic_only && !is_typed_only) { - std::cout << "value/test." << std::endl; - std::cout << " case/0 # GetParam() = 1" << std::endl; - std::cout << " case/1 # GetParam() = \"foo\"" << std::endl; - std::cout << "param/special." << std::endl; - std::cout << " case/0 # GetParam() = \"semicolon;\"" << std::endl; - std::cout << " case/1 # GetParam() = \"backslash\\\"" << std::endl; - std::cout << " case/2 # GetParam() = \"${var}\"" << std::endl; + const char* value_suite_names[] = { "value", "ns.value" }; + for (size_t i = 0; i < ARRAY_SIZE(value_suite_names); i++) { + std::cout << value_suite_names[i] << "/test." << std::endl; + std::cout << " case/0 # GetParam() = 1" << std::endl; + std::cout << " case/1 # GetParam() = \"foo\"" << std::endl; + } + const char* param_suite_names[] = { "param", "ns.param" }; + for (size_t j = 0; j < ARRAY_SIZE(param_suite_names); j++) { + std::cout << param_suite_names[j] << "/special." << std::endl; + std::cout << " case/0 # GetParam() = \"semicolon;\"" << std::endl; + std::cout << " case/1 # GetParam() = \"backslash\\\"" << std::endl; + std::cout << " case/2 # GetParam() = \"${var}\"" << std::endl; + } } return 0; } |