diff options
author | Pedro Navarro <pnavarro@netflix.com> | 2013-10-31 20:24:57 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2013-11-01 12:52:26 (GMT) |
commit | 1b54b1d5b7a48e8e804b32a56fc79b34ba1f0978 (patch) | |
tree | 46bf996cf965d140caae9885cf1bf3b728bed9bd /Tests/CTestUpdateCommon.cmake | |
parent | 7a616e75b84d692e2df453e889c12d1afdb6c576 (diff) | |
download | CMake-1b54b1d5b7a48e8e804b32a56fc79b34ba1f0978.zip CMake-1b54b1d5b7a48e8e804b32a56fc79b34ba1f0978.tar.gz CMake-1b54b1d5b7a48e8e804b32a56fc79b34ba1f0978.tar.bz2 |
ctest_update: Do not remove the p4 depot name
Instead of removing the depot name, which causes problems when looking
at the file change list in CDash, make the Update test remove a given
prefix from the files retrieved from Update.xml.
Diffstat (limited to 'Tests/CTestUpdateCommon.cmake')
-rw-r--r-- | Tests/CTestUpdateCommon.cmake | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Tests/CTestUpdateCommon.cmake b/Tests/CTestUpdateCommon.cmake index ae8fda2..db4e08d 100644 --- a/Tests/CTestUpdateCommon.cmake +++ b/Tests/CTestUpdateCommon.cmake @@ -37,10 +37,19 @@ function(check_updates build) REGEX "<(${types}|FullName)>" LIMIT_INPUT ${max_update_xml_size} ) + string(REGEX REPLACE "[ \t]*<(${types})>[ \t]*;[ \t]*<FullName>([^<]*)</FullName>" "\\1{\\2}" UPDATE_XML_ENTRIES "${UPDATE_XML_ENTRIES}") + # If specified, remove the given prefix from the files in Update.xml. + # Some VCS systems, like Perforce, return absolute locations + if(DEFINED REPOSITORY_FILE_PREFIX) + string(REPLACE + "${REPOSITORY_FILE_PREFIX}" "" + UPDATE_XML_ENTRIES "${UPDATE_XML_ENTRIES}") + endif() + # Compare expected and actual entries set(EXTRA "${UPDATE_XML_ENTRIES}") list(REMOVE_ITEM EXTRA ${ARGN} ${UPDATE_EXTRA} ${UPDATE_MAYBE}) |