[Cmake-commits] CMake branch, master, updated. a2fe175647718a562e41c84717b67917adbe584d
cmake-commits at cmake.org
cmake-commits at cmake.org
Thu Mar 18 10:29:12 EDT 2010
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, master has been updated
via a2fe175647718a562e41c84717b67917adbe584d (commit)
from 1560d9dcca7312def996022b4702dc739ba2badb (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a2fe175647718a562e41c84717b67917adbe584d
commit a2fe175647718a562e41c84717b67917adbe584d
Author: Zach Mullen <zach.mullen at kitware.com>
Date: Thu Mar 18 10:28:10 2010 -0400
More debugging of StopTime test
diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx
index 549de81..8e7b9cd 100644
--- a/Source/CTest/cmCTestRunTest.cxx
+++ b/Source/CTest/cmCTestRunTest.cxx
@@ -545,6 +545,8 @@ double cmCTestRunTest::ResolveTimeout()
this->CTest->GetStopTime().c_str(),
timezone);
+ cmCTestLog(this->CTest, HANDLER_OUTPUT, "Computed stop time="
+ << buf << std::endl);
time_t stop_time = curl_getdate(buf, ¤t_time);
if(stop_time == -1)
{
diff --git a/Tests/CTestTestStopTime/GetDate.cmake b/Tests/CTestTestStopTime/GetDate.cmake
index 71d1213..b793306 100644
--- a/Tests/CTestTestStopTime/GetDate.cmake
+++ b/Tests/CTestTestStopTime/GetDate.cmake
@@ -216,4 +216,18 @@ MACRO(ADD_SECONDS sec)
math(EXPR new_hr "${${GD_PREFIX}HOUR} + 1")
endwhile()
math(EXPR new_hr "${new_hr} % 24")
+
+ # Pad the H, M, S if needed
+ string(LENGTH ${new_sec} sec_len)
+ string(LENGTH ${new_min} min_len)
+ string(LENGTH ${new_hr} hr_len)
+ if(${sec_len} EQUAL 1)
+ set(new_sec "0${new_sec}")
+ endif()
+ if(${min_len} EQUAL 1)
+ set(new_min "0${new_min}")
+ endif()
+ if(${hr_len} EQUAL 1)
+ set(new_hr "0${new_hr}")
+ endif()
ENDMACRO(ADD_SECONDS)
diff --git a/Tests/CTestTestStopTime/test.cmake.in b/Tests/CTestTestStopTime/test.cmake.in
index cf212cc..0d664ad 100644
--- a/Tests/CTestTestStopTime/test.cmake.in
+++ b/Tests/CTestTestStopTime/test.cmake.in
@@ -26,10 +26,9 @@ CTEST_BUILD(BUILD "${CTEST_BINARY_DIRECTORY}" RETURN_VALUE res)
GET_DATE()
message("original time: ${${GD_PREFIX}HOUR}:${${GD_PREFIX}MINUTE}:${${GD_PREFIX}SECOND}")
-ADD_SECONDS(15)
+ADD_SECONDS(25)
message("stop time: ${new_hr}:${new_min}:${new_sec}")
CTEST_TEST(BUILD "${CTEST_BINARY_DIRECTORY}" RETURN_VALUE res STOP_TIME "${new_hr}:${new_min}:${new_sec}")
-GET_DATE()
-message("finish time: ${${GD_PREFIX}HOUR}:${${GD_PREFIX}MINUTE}:${${GD_PREFIX}SECOND}")
+
#CTEST_SUBMIT()
-----------------------------------------------------------------------
Summary of changes:
Source/CTest/cmCTestRunTest.cxx | 2 ++
Tests/CTestTestStopTime/GetDate.cmake | 14 ++++++++++++++
Tests/CTestTestStopTime/test.cmake.in | 5 ++---
3 files changed, 18 insertions(+), 3 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list