ENH: Extend CTest.UpdateSVN to test local mods
This teaches the test to create local modifications in the work tree before updating.
This commit is contained in:
parent
8c3290b4a3
commit
7960f7541c
|
@ -102,6 +102,9 @@ run_child(
|
|||
COMMAND ${CVSCMD} up -rRevision1
|
||||
)
|
||||
|
||||
# Create a modified file.
|
||||
modify_content(user-source)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Test updating the user work directory with the command-line interface.
|
||||
message("Running CTest Dashboard Command Line...")
|
||||
|
|
|
@ -109,6 +109,12 @@ function(change_content dir)
|
|||
file(APPEND ${TOP}/${dir}/subdir/foo.txt "foo line 2\n")
|
||||
endfunction(change_content)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Function to create local modifications before update
|
||||
function(modify_content dir)
|
||||
file(APPEND ${TOP}/${dir}/CTestConfig.cmake "# local modification\n")
|
||||
endfunction(modify_content)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Function to write CTestConfiguration.ini content.
|
||||
function(create_build_tree src_dir bin_dir)
|
||||
|
@ -149,7 +155,7 @@ function(run_dashboard_command_line bin_dir)
|
|||
)
|
||||
|
||||
# Verify the updates reported by CTest.
|
||||
check_updates(${bin_dir} foo.txt bar.txt zot.txt
|
||||
check_updates(${bin_dir} foo.txt bar.txt zot.txt CTestConfig.cmake
|
||||
subdir/foo.txt subdir/bar.txt)
|
||||
endfunction(run_dashboard_command_line)
|
||||
|
||||
|
|
|
@ -103,6 +103,9 @@ run_child(
|
|||
COMMAND ${SVNCMD} up -r1
|
||||
)
|
||||
|
||||
# Create a modified file.
|
||||
modify_content(user-source)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Test updating the user work directory with the command-line interface.
|
||||
message("Running CTest Dashboard Command Line...")
|
||||
|
|
Loading…
Reference in New Issue