You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2014/05/13 15:28:04 UTC
svn commit: r1594223 -
/subversion/trunk/subversion/tests/cmdline/lock_tests.py
Author: stsp
Date: Tue May 13 13:28:03 2014
New Revision: 1594223
URL: http://svn.apache.org/r1594223
Log:
Add a regression test for a bug observed in 1.8.x clients where locking and
committing the deletion of a path containing '%' fails with 400 'Bad Request'.
This test passes on trunk but fails on the 1.8.x branch.
* subversion/tests/cmdline/lock_tests.py
(delete_locked_file_with_percent, test_list): New.
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=1594223&r1=1594222&r2=1594223&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/lock_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/lock_tests.py Tue May 13 13:28:03 2014
@@ -2271,6 +2271,27 @@ def dav_lock_refresh(sbox):
if r.status != httplib.OK:
raise svntest.Failure('Lock refresh failed: %d %s' % (r.status, r.reason))
+@SkipUnless(svntest.main.is_ra_type_dav)
+def delete_locked_file_with_percent(sbox):
+ "lock and delete a file called 'a %( ) .txt'"
+
+ sbox.build()
+
+ locked_filename = 'a %( ) .txt'
+ locked_path = sbox.ospath(locked_filename)
+ svntest.main.file_write(locked_path, "content\n")
+ sbox.simple_add(locked_filename)
+ sbox.simple_commit()
+
+ sbox.simple_lock(locked_filename)
+ sbox.simple_rm(locked_filename)
+
+ # XFAIL: With a 1.8.x client, this commit fails with:
+ # svn: E175002: Unexpected HTTP status 400 'Bad Request' on '/svn-test-work/repositories/lock_tests-52/!svn/txr/2-2/a%20%25(%20)%20.txt'
+ # and the following error in the httpd error log:
+ # Invalid percent encoded URI in tagged If-header [400, #104]
+ sbox.simple_commit()
+
########################################################################
# Run the tests
@@ -2333,6 +2354,7 @@ test_list = [ None,
non_root_locks,
many_locks_hooks,
dav_lock_refresh,
+ delete_locked_file_with_percent,
]
if __name__ == '__main__':