You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by hw...@apache.org on 2010/03/16 15:39:12 UTC

svn commit: r923768 - in /subversion/branches/1.6.x: ./ CHANGES STATUS subversion/libsvn_wc/props.c subversion/tests/cmdline/update_tests.py

Author: hwright
Date: Tue Mar 16 14:39:12 2010
New Revision: 923768

URL: http://svn.apache.org/viewvc?rev=923768&view=rev
Log:
Reintegrate the r906256 branch:

 * r906256, r906305
   Fix issue #3573 'local non-inheritable mergeinfo changes not properly
   merged with updated mergeinfo'
   Notes:
   Justification:
     svn:mergeinfo should be mergeable, but in this issue mergeinfo changes
     brought down by an update were not properly merged with local changes.
   Notes:
     r906256 is a test demonstrating the problem and r906305 is the fix.
   Branch:
     ^/subversion/branches/1.6.x-issue3573
   Votes:
     +1: pburba, cmpilato, rhuijben

Modified:
    subversion/branches/1.6.x/   (props changed)
    subversion/branches/1.6.x/CHANGES   (props changed)
    subversion/branches/1.6.x/STATUS
    subversion/branches/1.6.x/subversion/libsvn_wc/props.c
    subversion/branches/1.6.x/subversion/tests/cmdline/update_tests.py

Propchange: subversion/branches/1.6.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 16 14:39:12 2010
@@ -5,6 +5,7 @@
 /subversion/branches/1.6.x-future-proof:880259-884209
 /subversion/branches/1.6.x-issue3443:874942-875825
 /subversion/branches/1.6.x-issue3519:880376-889934
+/subversion/branches/1.6.x-issue3573:906488-923765
 /subversion/branches/1.6.x-no-svn_uri:872705-872760
 /subversion/branches/1.6.x-r36178:874221-874229
 /subversion/branches/1.6.x-r36252:872673-873133
@@ -57,4 +58,4 @@
 /subversion/branches/tc_url_rev:870696-870828
 /subversion/branches/tree-conflicts:864636-869499
 /subversion/branches/tree-conflicts-notify:870271-870353
-/subversion/trunk:875976,875980-875981,876054-876056,876092,876175,876299,876306,876427,876440,876450,876507,876571,879093,879688,880274-880275,880370,880450,880474,880525-880526,880552,881905,884842,886164,886197,888715,888979,889081,889840,891672,895514,895653,896522,898963,899826,899828,900797,901752,904594,905303,905326,922516
+/subversion/trunk:875976,875980-875981,876054-876056,876092,876175,876299,876306,876427,876440,876450,876507,876571,879093,879688,880274-880275,880370,880450,880474,880525-880526,880552,881905,884842,886164,886197,888715,888979,889081,889840,891672,895514,895653,896522,898963,899826,899828,900797,901752,904594,905303,905326,906256,906305,922516

Propchange: subversion/branches/1.6.x/CHANGES
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 16 14:39:12 2010
@@ -5,6 +5,7 @@
 /subversion/branches/1.6.x-future-proof/CHANGES:880259-884209
 /subversion/branches/1.6.x-issue3443/CHANGES:874942-875825
 /subversion/branches/1.6.x-issue3519/CHANGES:880376-889934
+/subversion/branches/1.6.x-issue3573/CHANGES:906488-923765
 /subversion/branches/1.6.x-no-svn_uri/CHANGES:872705-872760
 /subversion/branches/1.6.x-r36178/CHANGES:874221-874229
 /subversion/branches/1.6.x-r36252/CHANGES:872673-873133

Modified: subversion/branches/1.6.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/STATUS?rev=923768&r1=923767&r2=923768&view=diff
==============================================================================
--- subversion/branches/1.6.x/STATUS (original)
+++ subversion/branches/1.6.x/STATUS Tue Mar 16 14:39:12 2010
@@ -238,20 +238,6 @@ Approved changes:
    Votes:
      +1: neels, cmpilato, rhuijben
 
- * r906256, r906305
-   Fix issue #3573 'local non-inheritable mergeinfo changes not properly
-   merged with updated mergeinfo'
-   Notes:
-   Justification:
-     svn:mergeinfo should be mergeable, but in this issue mergeinfo changes
-     brought down by an update were not properly merged with local changes.
-   Notes:
-     r906256 is a test demonstrating the problem and r906305 is the fix.
-   Branch:
-     ^/subversion/branches/1.6.x-issue3573
-   Votes:
-     +1: pburba, cmpilato, rhuijben
-
  * r917640, r918211
    Correctly handle invocations of 'svnlook plist --revprop' when
    used with '-t TXN_NAME' instead of '-r REV'.

Modified: subversion/branches/1.6.x/subversion/libsvn_wc/props.c
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/subversion/libsvn_wc/props.c?rev=923768&r1=923767&r2=923768&view=diff
==============================================================================
--- subversion/branches/1.6.x/subversion/libsvn_wc/props.c (original)
+++ subversion/branches/1.6.x/subversion/libsvn_wc/props.c Tue Mar 16 14:39:12 2010
@@ -926,7 +926,7 @@ diff_mergeinfo_props(svn_mergeinfo_t *de
       SVN_ERR(svn_mergeinfo_parse(&from, from_prop_val->data, pool));
       SVN_ERR(svn_mergeinfo_parse(&to, to_prop_val->data, pool));
       SVN_ERR(svn_mergeinfo_diff(deleted, added, from, to,
-                                 FALSE, pool));
+                                 TRUE, pool));
     }
   return SVN_NO_ERROR;
 }

Modified: subversion/branches/1.6.x/subversion/tests/cmdline/update_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x/subversion/tests/cmdline/update_tests.py?rev=923768&r1=923767&r2=923768&view=diff
==============================================================================
--- subversion/branches/1.6.x/subversion/tests/cmdline/update_tests.py (original)
+++ subversion/branches/1.6.x/subversion/tests/cmdline/update_tests.py Tue Mar 16 14:39:12 2010
@@ -22,6 +22,7 @@ import sys, re, os, subprocess
 # Our testing module
 import svntest
 from svntest import wc
+from merge_tests import set_up_branch
 
 # (abbreviation)
 Skip = svntest.testcase.Skip
@@ -4750,6 +4751,62 @@ def update_wc_of_dir_to_rev_not_containi
                                      "svn: Target path '/A' does not exist",
                                      "up", other_wc_dir)
 
+#----------------------------------------------------------------------
+# Test for issue #3573 'local non-inheritable mergeinfo changes not
+# properly merged with updated mergeinfo'
+def mergeinfo_updates_merge_with_local_mods(sbox):
+  "local mergeinfo changes are merged with updates"
+
+  # Copy A to A_COPY in r2, and make some changes to A_COPY in r3-r6.
+  sbox.build()
+  wc_dir = sbox.wc_dir
+  expected_disk, expected_status = set_up_branch(sbox)
+
+  # Some paths we'll care about
+  A_path      = os.path.join(wc_dir, "A")
+  A_COPY_path = os.path.join(wc_dir, "A_COPY")
+
+  # Merge -c3 from A to A_COPY at --depth empty, commit as r7.
+  ###
+  ### No, we are not checking the merge output for these simple
+  ### merges.  This is already covered *TO DEATH* in merge_tests.py.
+  ###
+  svntest.actions.run_and_verify_svn(None, None, [], 'up', wc_dir)
+  svntest.actions.run_and_verify_svn(None, None, [],
+                                     'merge', '-c3', '--depth', 'empty',
+                                     sbox.repo_url + '/A', A_COPY_path)
+  svntest.actions.run_and_verify_svn(None, None, [], 'ci', '-m',
+                                     'Merge r3 from A to A_COPY at depth empty',
+                                     wc_dir)
+  # Merge -c5 from A to A_COPY (at default --depth infinity), commit as r8.
+  svntest.actions.run_and_verify_svn(None, None, [], 'up', wc_dir)
+  svntest.actions.run_and_verify_svn(None, None, [],
+                                     'merge', '-c5',
+                                     sbox.repo_url + '/A', A_COPY_path)
+  svntest.actions.run_and_verify_svn(None, None, [], 'ci', '-m',
+                                     'Merge r5 from A to A_COPY', wc_dir)
+
+  # Update WC to r7, repeat merge of -c3 from A to A_COPY but this
+  # time do it at --depth infinity.  Confirm that the mergeinfo
+  # on A_COPY is no longer inheritable.
+  svntest.actions.run_and_verify_svn(None, None, [], 'up', '-r7', wc_dir)
+  svntest.actions.run_and_verify_svn(None, None, [],
+                                     'merge', '-c3', '--depth', 'infinity',
+                                     sbox.repo_url + '/A', A_COPY_path)
+  svntest.actions.run_and_verify_svn(None, [A_COPY_path + " - /A:3\n"], [],
+                                     'pg', SVN_PROP_MERGEINFO, '-R',
+                                     A_COPY_path) 
+
+  # Update the WC (to r8), the mergeinfo on A_COPY should now have both
+  # the local mod from the uncommitted merge (/A:3* --> /A:3) and the change
+  # brought down by the update (/A:3* --> /A:3*,5) leaving us with /A:3,5.
+  ### This was failing because of issue #3573.  The local mergeinfo change
+  ### is reverted, leaving '/A:3*,5' on A_COPY.
+  svntest.actions.run_and_verify_svn(None, None, [], 'up', wc_dir)
+  svntest.actions.run_and_verify_svn(None, [A_COPY_path + " - /A:3,5\n"], [],
+                                     'pg', SVN_PROP_MERGEINFO, '-R',
+                                     A_COPY_path)
+
 #######################################################################
 # Run the tests
 
@@ -4815,6 +4872,7 @@ test_list = [ None,
               tree_conflict_uc2_schedule_re_add,
               set_deep_depth_on_target_with_shallow_children,
               update_wc_of_dir_to_rev_not_containing_this_dir,
+              mergeinfo_updates_merge_with_local_mods,
              ]
 
 if __name__ == '__main__':