You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ju...@apache.org on 2011/05/06 20:48:12 UTC
svn commit: r1100326 -
/subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py
Author: julianfoad
Date: Fri May 6 18:48:11 2011
New Revision: 1100326
URL: http://svn.apache.org/viewvc?rev=1100326&view=rev
Log:
* subversion/tests/cmdline/tree_conflict_tests.py
(ensure_tree_conflict): Start checking the 'svn info' output for each
tree conflict.
Modified:
subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py
Modified: subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py?rev=1100326&r1=1100325&r2=1100326&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/tree_conflict_tests.py Fri May 6 18:48:11 2011
@@ -35,6 +35,7 @@ from svntest.actions import run_and_veri
from svntest.actions import run_and_verify_resolved
from svntest.actions import run_and_verify_update
from svntest.actions import run_and_verify_status
+from svntest.actions import run_and_verify_info
from svntest.actions import get_virginal_state
# (abbreviation)
@@ -438,9 +439,10 @@ def ensure_tree_conflict(sbox, operation
target_path)
if modaction.startswith('f'):
- victim_path = os.path.join(target_path, 'F')
+ victim_name = 'F'
else:
- victim_path = os.path.join(target_path, 'D')
+ victim_name = 'D'
+ victim_path = os.path.join(target_path, victim_name)
# Perform the operation that tries to apply incoming changes to the WC.
# The command is expected to do something (and give some output),
@@ -467,6 +469,22 @@ def ensure_tree_conflict(sbox, operation
else:
raise Exception("unknown operation: '" + operation + "'")
+ verbose_print("--- Checking that 'info' reports the conflict")
+ if operation == 'update' or operation == 'switch':
+ incoming_left_rev = target_start_rev
+ else:
+ incoming_left_rev = source_left_rev
+ if operation == 'update' or operation == 'merge':
+ incoming_right_rev = source_right_rev
+ else:
+ incoming_right_rev = head_rev
+ expected_info = { 'Tree conflict' : operation +
+ r'.* \((none|(file|dir).*' +
+ re.escape(victim_name + '@' + str(incoming_left_rev)) + r')' +
+ r'.* \((none|(file|dir).*' +
+ re.escape(victim_name + '@' + str(incoming_right_rev)) + r')' }
+ run_and_verify_info([expected_info], victim_path)
+
verbose_print("--- Trying to commit (expecting 'conflict' error)")
### run_and_verify_commit() requires an "output_tree" argument, but
# here we get away with passing None because we know an implementation