You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2014/12/08 13:20:38 UTC
svn commit: r1643797 -
/subversion/trunk/subversion/tests/cmdline/lock_tests.py
Author: rhuijben
Date: Mon Dec 8 12:20:38 2014
New Revision: 1643797
URL: http://svn.apache.org/r1643797
Log:
Add simple regression test on lock handling during copy and move (to easily
trigger some code in mod_dav that I tried to look at).
* subversion/tests/cmdline/lock_tests.py
(copy_dir_with_locked_file): New function.
(test_list): Add copy_dir_with_locked_file.
Modified:
subversion/trunk/subversion/tests/cmdline/lock_tests.py
Modified: subversion/trunk/subversion/tests/cmdline/lock_tests.py
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/lock_tests.py?rev=1643797&r1=1643796&r2=1643797&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/lock_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/lock_tests.py Mon Dec 8 12:20:38 2014
@@ -2355,6 +2355,26 @@ def lock_commit_bump(sbox):
svntest.actions.run_and_verify_info(expected_infos,
sbox.ospath('iota'))
+def copy_dir_with_locked_file(sbox):
+ "copy a directory containing a locked file"
+
+ sbox.build()
+ AA_url = sbox.repo_url + '/AA'
+ AA2_url = sbox.repo_url + '/AA2'
+ A_url = sbox.repo_url + '/A'
+ mu_url = A_url + '/mu'
+
+ svntest.main.run_svn(None, 'lock', '-m', 'locked', mu_url)
+
+ svntest.actions.run_and_verify_svn(None, None, [],
+ 'cp', A_url, AA_url,
+ '-m', '')
+
+ expected_err = "svn: E160037: .*no matching lock-token available"
+ svntest.actions.run_and_verify_svn(None, None, expected_err,
+ 'mv', A_url, AA2_url,
+ '-m', '')
+
########################################################################
# Run the tests
@@ -2420,6 +2440,7 @@ test_list = [ None,
dav_lock_refresh,
delete_locked_file_with_percent,
lock_commit_bump,
+ copy_dir_with_locked_file,
]
if __name__ == '__main__':