summaryrefslogtreecommitdiffstats
path: root/Tests/CTestCoverageCollectGCOV/fakegcov.cmake
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2015-01-28 22:08:41 (GMT)
committerBrad King <brad.king@kitware.com>2015-02-03 15:40:58 (GMT)
commit8caa4e72abe4393914f4dcefd1621d3c86a7d139 (patch)
tree8049f1beaa5c0e461d50913c400c19f74c87155d /Tests/CTestCoverageCollectGCOV/fakegcov.cmake
parent5c828cc89b4f78eceaf0402719cf5693a6627935 (diff)
downloadCMake-8caa4e72abe4393914f4dcefd1621d3c86a7d139.zip
CMake-8caa4e72abe4393914f4dcefd1621d3c86a7d139.tar.gz
CMake-8caa4e72abe4393914f4dcefd1621d3c86a7d139.tar.bz2
CTestCoverageCollectGCOV: Add test case
Diffstat (limited to 'Tests/CTestCoverageCollectGCOV/fakegcov.cmake')
-rw-r--r--Tests/CTestCoverageCollectGCOV/fakegcov.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/Tests/CTestCoverageCollectGCOV/fakegcov.cmake b/Tests/CTestCoverageCollectGCOV/fakegcov.cmake
new file mode 100644
index 0000000..e704f14
--- /dev/null
+++ b/Tests/CTestCoverageCollectGCOV/fakegcov.cmake
@@ -0,0 +1,8 @@
+foreach(I RANGE 0 ${CMAKE_ARGC})
+ if("${CMAKE_ARGV${I}}" MATCHES ".*\\.gcda")
+ set(gcda_file "${CMAKE_ARGV${I}}")
+ endif()
+endforeach()
+get_filename_component(gcda_file ${gcda_file} NAME_WE)
+file(WRITE "${CMAKE_SOURCE_DIR}/${gcda_file}.gcov"
+"fake gcov file")