diff options
| author | Martin Hořeňovský | 2019-10-09 14:16:50 +0200 |
|---|---|---|
| committer | GitHub | 2019-10-09 14:16:50 +0200 |
| commit | 1c5749669e85239ce3dd3bb80028d9b8d2402787 (patch) | |
| tree | 03ca9d9acc16ca5a2ff5c1e9be23adee9b413ac9 /projects | |
| parent | 75200e199e76b246a3e314e70ec181b32baab08a (diff) | |
| parent | 3109add95ccbc0b388e874253a7894027726cb0c (diff) | |
| download | catch3-1c5749669e85239ce3dd3bb80028d9b8d2402787.tar.gz | |
Merge pull request #1769 from amitherman95/amitherman-1767
Patch:Failure to pass special chars through input file
Diffstat (limited to 'projects')
| -rw-r--r-- | projects/CMakeLists.txt | 6 | ||||
| -rw-r--r-- | projects/SelfTest/Misc/plain-old-tests.input | 2 | ||||
| -rw-r--r-- | projects/SelfTest/Misc/special-characters-in-file.input | 1 |
3 files changed, 9 insertions, 0 deletions
diff --git a/projects/CMakeLists.txt b/projects/CMakeLists.txt index b2c67a64..8d0f94d4 100644 --- a/projects/CMakeLists.txt +++ b/projects/CMakeLists.txt @@ -433,6 +433,12 @@ set_tests_properties(FilenameAsTagsTest PROPERTIES PASS_REGULAR_EXPRESSION "\\[# add_test(NAME EscapeSpecialCharactersInTestNames COMMAND $<TARGET_FILE:SelfTest> "Test with special\\, characters \"in name") set_tests_properties(EscapeSpecialCharactersInTestNames PROPERTIES PASS_REGULAR_EXPRESSION "1 assertion in 1 test case") +add_test(NAME SpecialCharactersInTestNamesFromFile COMMAND $<TARGET_FILE:SelfTest> "-f ${CATCH_DIR}/projects/SelfTest/Misc/special-characters-in-file.input") +set_tests_properties(SpecialCharactersInTestNamesFromFile PROPERTIES PASS_REGULAR_EXPRESSION "1 assertion in 1 test case") + +add_test(NAME RunningTestsFromFile COMMAND $<TARGET_FILE:SelfTest> "-f ${CATCH_DIR}/projects/SelfTest/Misc/plain-old-tests.input") +set_tests_properties(RunningTestsFromFile PROPERTIES PASS_REGULAR_EXPRESSION "6 assertions in 2 test cases") + if (CATCH_USE_VALGRIND) add_test(NAME ValgrindRunTests COMMAND valgrind --leak-check=full --error-exitcode=1 $<TARGET_FILE:SelfTest>) diff --git a/projects/SelfTest/Misc/plain-old-tests.input b/projects/SelfTest/Misc/plain-old-tests.input new file mode 100644 index 00000000..ae6d9f1b --- /dev/null +++ b/projects/SelfTest/Misc/plain-old-tests.input @@ -0,0 +1,2 @@ +random SECTION tests +nested SECTION tests diff --git a/projects/SelfTest/Misc/special-characters-in-file.input b/projects/SelfTest/Misc/special-characters-in-file.input new file mode 100644 index 00000000..b68a6bfd --- /dev/null +++ b/projects/SelfTest/Misc/special-characters-in-file.input @@ -0,0 +1 @@ +Test with special\, characters \"in name |