subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1483397 - in /subversion/trunk/subversion: libsvn_wc/diff_local.c tests/cmdline/diff_tests.py
Date Thu, 16 May 2013 14:56:37 GMT
Author: rhuijben
Date: Thu May 16 14:56:37 2013
New Revision: 1483397

URL: http://svn.apache.org/r1483397
Log:
Resolve an 1.8/trunk error when running diff on an actual only
tree conflict.

* subversion/libsvn_wc/diff_local.c
  (diff_status_callback): Don't report on actual only nodes.

* subversion/tests/cmdline/diff_tests.py
  (diff_missing_tree_conflict_victim): Remove XFail marker and extend test to
    also apply a change on a directory.

Modified:
    subversion/trunk/subversion/libsvn_wc/diff_local.c
    subversion/trunk/subversion/tests/cmdline/diff_tests.py

Modified: subversion/trunk/subversion/libsvn_wc/diff_local.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/diff_local.c?rev=1483397&r1=1483396&r2=1483397&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/diff_local.c (original)
+++ subversion/trunk/subversion/libsvn_wc/diff_local.c Thu May 16 14:56:37 2013
@@ -201,6 +201,15 @@ diff_status_callback(void *baton,
       case svn_wc_status_ignored:
         return SVN_NO_ERROR; /* No diff */
 
+      case svn_wc_status_conflicted:
+        if (status->text_status == svn_wc_status_none
+            && status->prop_status == svn_wc_status_none)
+          {
+            /* Node is an actual only node describing a tree conflict */
+            return SVN_NO_ERROR;
+          }
+        break;
+
       default:
         break; /* Go check other conditions */
     }

Modified: subversion/trunk/subversion/tests/cmdline/diff_tests.py
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/diff_tests.py?rev=1483397&r1=1483396&r2=1483397&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/diff_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/diff_tests.py Thu May 16 14:56:37 2013
@@ -4535,7 +4535,6 @@ def diff_repos_empty_file_addition(sbox)
   svntest.actions.run_and_verify_svn(None, expected_output, [],
                                      'diff', '-c', '2', sbox.repo_url)
 
-@XFail()
 def diff_missing_tree_conflict_victim(sbox):
   "diff with missing tree-conflict victim in wc"
 
@@ -4545,21 +4544,25 @@ def diff_missing_tree_conflict_victim(sb
   # Produce an 'incoming edit vs. local missing' tree conflict:
   # r2: edit iota and commit the change
   svntest.main.file_append(sbox.ospath('iota'), "This is a change to iota.\n")
-  sbox.simple_commit('iota')
+  sbox.simple_propset('k', 'v', 'A/C')
+  sbox.simple_commit()
   # now remove iota
-  sbox.simple_rm('iota')
-  sbox.simple_commit('iota')
+  sbox.simple_rm('iota', 'A/C')
+  sbox.simple_commit()
   # update to avoid mixed-rev wc warning
   sbox.simple_update()
   # merge r2 into wc and verify that a tree conflict is flagged on iota
-  expected_output = wc.State(wc_dir, {'iota' : Item(status='  ',
-                                                    treeconflict='C')})
+  expected_output = wc.State(wc_dir, {
+      'iota' : Item(status='  ', treeconflict='C'),
+      'A/C' : Item(status='  ', treeconflict='C')
+  })
   expected_mergeinfo_output = wc.State(wc_dir, {})
   expected_elision_output = wc.State(wc_dir, {})
   expected_disk = svntest.main.greek_state.copy()
-  expected_disk.remove('iota')
+  expected_disk.remove('iota','A/C')
   expected_status = svntest.actions.get_virginal_state(wc_dir, 3)
-  expected_status.add({'iota' : Item(status='! ', treeconflict='C')})
+  expected_status.tweak('iota', 'A/C',
+                        status='! ', treeconflict='C', wc_rev=None)
   expected_skip = wc.State('', { })
   svntest.actions.run_and_verify_merge(wc_dir, '1', '2',
                                        sbox.repo_url, None,



Mime
View raw message