summaryrefslogtreecommitdiffstats
path: root/config/cmake_ext_mod/grepTest.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'config/cmake_ext_mod/grepTest.cmake')
-rw-r--r--config/cmake_ext_mod/grepTest.cmake10
1 files changed, 5 insertions, 5 deletions
diff --git a/config/cmake_ext_mod/grepTest.cmake b/config/cmake_ext_mod/grepTest.cmake
index 5f07134..a090057 100644
--- a/config/cmake_ext_mod/grepTest.cmake
+++ b/config/cmake_ext_mod/grepTest.cmake
@@ -33,7 +33,7 @@ execute_process (
RESULT_VARIABLE TEST_RESULT
OUTPUT_FILE ${TEST_OUTPUT}
ERROR_FILE ${TEST_OUTPUT}.err
- OUTPUT_VARIABLE TEST_ERROR
+ OUTPUT_VARIABLE TEST_OUT
ERROR_VARIABLE TEST_ERROR
)
@@ -44,16 +44,16 @@ message (STATUS "COMMAND Error: ${TEST_ERROR}")
file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
# TEST_REFERENCE should always be matched
-string (REGEX MATCH "${TEST_REFERENCE}" TEST_MATCH ${TEST_STREAM})
-string (COMPARE EQUAL "${TEST_REFERENCE}" "${TEST_MATCH}" TEST_RESULT)
+string (REGEX MATCH "${TEST_REFERENCE}" TEST_MATCH ${TEST_STREAM})
+string (COMPARE EQUAL "${TEST_REFERENCE}" "${TEST_MATCH}" TEST_RESULT)
if (${TEST_RESULT} STREQUAL "0")
message (FATAL_ERROR "Failed: The output of ${TEST_PROGRAM} did not contain ${TEST_REFERENCE}")
endif (${TEST_RESULT} STREQUAL "0")
-string (REGEX MATCH "${TEST_FILTER}" TEST_MATCH ${TEST_STREAM})
+string (REGEX MATCH "${TEST_FILTER}" TEST_MATCH ${TEST_STREAM})
if (${TEST_EXPECT} STREQUAL "1")
# TEST_EXPECT (1) interperts TEST_FILTER as NOT to match
- string (LENGTH "${TEST_MATCH}" TEST_RESULT)
+ string (LENGTH "${TEST_MATCH}" TEST_RESULT)
if (NOT ${TEST_RESULT} STREQUAL "0")
message (FATAL_ERROR "Failed: The output of ${TEST_PROGRAM} did contain ${TEST_FILTER}")
endif (NOT ${TEST_RESULT} STREQUAL "0")