You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by pr...@apache.org on 2013/01/29 10:40:42 UTC

svn commit: r1439801 - in /subversion/branches/verify-keep-going: ./ subversion/libsvn_fs/ subversion/libsvn_wc/ subversion/tests/cmdline/ subversion/tests/cmdline/upgrade_tests_data/ tools/dist/

Author: prabhugs
Date: Tue Jan 29 09:40:41 2013
New Revision: 1439801

URL: http://svn.apache.org/viewvc?rev=1439801&view=rev
Log:
Reverse merged r1439765 and merging r1439280 through r1439797 from trunk into verify-keep-going branch.

Added:
    subversion/branches/verify-keep-going/subversion/tests/cmdline/upgrade_tests_data/upgrade_from_1_7_wc.tar.bz2
      - copied unchanged from r1439797, subversion/trunk/subversion/tests/cmdline/upgrade_tests_data/upgrade_from_1_7_wc.tar.bz2
Modified:
    subversion/branches/verify-keep-going/   (props changed)
    subversion/branches/verify-keep-going/subversion/libsvn_fs/fs-loader.c
    subversion/branches/verify-keep-going/subversion/libsvn_wc/wc_db_update_move.c
    subversion/branches/verify-keep-going/subversion/tests/cmdline/svnadmin_tests.py
    subversion/branches/verify-keep-going/subversion/tests/cmdline/update_tests.py
    subversion/branches/verify-keep-going/tools/dist/make-deps-tarball.sh   (props changed)

Propchange: subversion/branches/verify-keep-going/
------------------------------------------------------------------------------
  Merged /subversion/trunk:r1439755-1439797

Modified: subversion/branches/verify-keep-going/subversion/libsvn_fs/fs-loader.c
URL: http://svn.apache.org/viewvc/subversion/branches/verify-keep-going/subversion/libsvn_fs/fs-loader.c?rev=1439801&r1=1439800&r2=1439801&view=diff
==============================================================================
--- subversion/branches/verify-keep-going/subversion/libsvn_fs/fs-loader.c (original)
+++ subversion/branches/verify-keep-going/subversion/libsvn_fs/fs-loader.c Tue Jan 29 09:40:41 2013
@@ -498,9 +498,10 @@ svn_fs_verify(const char *path,
   fs = fs_new(NULL, pool);
 
   SVN_MUTEX__WITH_LOCK(common_pool_lock,
-                       vtable->verify_fs(fs, path, cancel_func, cancel_baton,
-                                         notify_func, notify_baton, start,
-                                         end, pool, common_pool));
+                       vtable->verify_fs(fs, path, start, end,
+                                         notify_func, notify_baton,
+                                         cancel_func, cancel_baton,
+                                         pool, common_pool));
   return SVN_NO_ERROR;
 }
 

Modified: subversion/branches/verify-keep-going/subversion/libsvn_wc/wc_db_update_move.c
URL: http://svn.apache.org/viewvc/subversion/branches/verify-keep-going/subversion/libsvn_wc/wc_db_update_move.c?rev=1439801&r1=1439800&r2=1439801&view=diff
==============================================================================
--- subversion/branches/verify-keep-going/subversion/libsvn_wc/wc_db_update_move.c (original)
+++ subversion/branches/verify-keep-going/subversion/libsvn_wc/wc_db_update_move.c Tue Jan 29 09:40:41 2013
@@ -506,6 +506,7 @@ update_working_props(svn_wc_notify_state
                      apr_pool_t *scratch_pool)
 {
   apr_hash_t *new_actual_props;
+  apr_array_header_t *new_propchanges;
 
   /*
    * Run a 3-way prop merge to update the props, using the pre-update
@@ -524,6 +525,18 @@ update_working_props(svn_wc_notify_state
                               old_version->props, old_version->props,
                               *actual_props, *propchanges,
                               result_pool, scratch_pool));
+
+  /* Setting properties in ACTUAL_NODE with svn_wc__db_op_set_props
+     relies on NODES row having been updated first which we don't do
+     at present. So this extra property diff has the same effect.
+
+     ### Perhaps we should update NODES first (but after
+     ### svn_wc__db_read_props above)?  */
+  SVN_ERR(svn_prop_diffs(&new_propchanges, new_actual_props, new_version->props,
+                         scratch_pool));
+  if (!new_propchanges->nelts)
+    new_actual_props = NULL;
+
   /* Install the new actual props. Don't set the conflict_skel yet, because
      we might need to add a text conflict to it as well. */
   SVN_ERR(svn_wc__db_op_set_props(db, local_abspath,
@@ -535,7 +548,6 @@ update_working_props(svn_wc_notify_state
   return SVN_NO_ERROR;
 }
 
-
 static svn_error_t *
 tc_editor_alter_directory(void *baton,
                           const char *dst_relpath,

Modified: subversion/branches/verify-keep-going/subversion/tests/cmdline/svnadmin_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/verify-keep-going/subversion/tests/cmdline/svnadmin_tests.py?rev=1439801&r1=1439800&r2=1439801&view=diff
==============================================================================
--- subversion/branches/verify-keep-going/subversion/tests/cmdline/svnadmin_tests.py (original)
+++ subversion/branches/verify-keep-going/subversion/tests/cmdline/svnadmin_tests.py Tue Jan 29 09:40:41 2013
@@ -554,7 +554,7 @@ def verify_windows_paths_in_repos(sbox):
   if svntest.main.is_fs_type_fsfs():
     svntest.verify.compare_and_display_lines(
       "Error while running 'svnadmin verify'.",
-      'STDERR', ["* Verifying global structure ...\n",
+      'STDERR', ["* Verifying repository metadata ...\n",
                  "* Verified revision 0.\n",
                  "* Verified revision 1.\n",
                  "* Verified revision 2.\n"], errput)

Modified: subversion/branches/verify-keep-going/subversion/tests/cmdline/update_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/verify-keep-going/subversion/tests/cmdline/update_tests.py?rev=1439801&r1=1439800&r2=1439801&view=diff
==============================================================================
--- subversion/branches/verify-keep-going/subversion/tests/cmdline/update_tests.py (original)
+++ subversion/branches/verify-keep-going/subversion/tests/cmdline/update_tests.py Tue Jan 29 09:40:41 2013
@@ -6463,6 +6463,80 @@ def update_swapped_depth_dirs(sbox):
                                         None, None, None,
                                         None, None, 1)
 
+def move_update_props(sbox):
+  "move-update with property mods"
+
+  sbox.build()
+  wc_dir = sbox.wc_dir
+
+  # Commit some 'future' property changes
+  sbox.simple_propset('propertyA', 'value1',
+                      'A/B', 'A/B/E', 'A/B/E/alpha', 'A/B/E/beta')
+  sbox.simple_commit()
+  sbox.simple_propset('propertyB', 'value2',
+                      'A/B', 'A/B/E', 'A/B/E/alpha', 'A/B/E/beta')
+  sbox.simple_commit()
+  sbox.simple_update(revision=1)
+
+  # Make some local property changes
+  sbox.simple_propset('propertyB', 'value3',
+                      'A/B/E', 'A/B/E/beta')
+
+  sbox.simple_move("A/B", "A/B2")
+
+  # Update and expect a conflict
+  expected_output = svntest.wc.State(wc_dir, {
+      'A/B'         : Item(status='  ', treeconflict='C'),
+      'A/B/E'       : Item(status='  ', treeconflict='U'),
+      'A/B/E/alpha' : Item(status='  ', treeconflict='U'),
+      'A/B/E/beta'  : Item(status='  ', treeconflict='U'),
+      })
+  expected_disk = svntest.main.greek_state.copy()
+  expected_disk.remove('A/B/E/alpha', 'A/B/E/beta', 'A/B/E',
+                       'A/B/lambda', 'A/B/F', 'A/B')
+  expected_disk.add({
+      'A/B2'         : Item(),
+      'A/B2/E'       : Item(),
+      'A/B2/E/alpha' : Item(contents="This is the file 'alpha'.\n"),
+      'A/B2/E/beta'  : Item(contents="This is the file 'beta'.\n"),
+      'A/B2/F'       : Item(),
+      'A/B2/lambda'  : Item(contents="This is the file 'lambda'.\n"),
+      })
+  expected_disk.tweak('A/B2/E', 'A/B2/E/beta', props={'propertyB':'value3'})
+  expected_status = svntest.actions.get_virginal_state(wc_dir, 2)
+  expected_status.tweak('A/B', status='D ', treeconflict='C', moved_to='A/B2')
+  expected_status.tweak('A/B/E', 'A/B/E/alpha', 'A/B/E/beta',
+                        'A/B/F', 'A/B/lambda', status='D ')
+  expected_status.add({
+      'A/B2'         : Item(status='A ', copied='+', wc_rev='-',
+                            moved_from='A/B'),
+      'A/B2/E'       : Item(status=' M', copied='+', wc_rev='-'),
+      'A/B2/E/beta'  : Item(status=' M', copied='+', wc_rev='-'),
+      'A/B2/E/alpha' : Item(status='  ', copied='+', wc_rev='-'),
+      'A/B2/F'       : Item(status='  ', copied='+', wc_rev='-'),
+      'A/B2/lambda'  : Item(status='  ', copied='+', wc_rev='-'),
+      })
+  svntest.actions.run_and_verify_update(wc_dir,
+                                        expected_output,
+                                        expected_disk,
+                                        expected_status,
+                                        None, None, None,
+                                        None, None, 1,
+                                        '-r', '2', wc_dir)
+
+  # Resolve conflict moving changes to destination without conflict
+  svntest.actions.run_and_verify_svn("resolve failed", None, [],
+                                     'resolve',
+                                     '--accept=mine-conflict',
+                                     sbox.ospath('A/B'))
+
+  expected_status.tweak('A/B', treeconflict=None)
+  svntest.actions.run_and_verify_status(wc_dir, expected_status)
+
+  expected_disk.tweak('A/B2', 'A/B2/E/alpha', props={'propertyA' : 'value1'})
+  expected_disk.tweak('A/B2/E', 'A/B2/E/beta', props={'propertyA' : 'value1',
+                                                      'propertyB':'value3'})
+  svntest.actions.verify_disk(wc_dir, expected_disk, check_props = True)
 
   # Further update and expect a conflict.
   expected_status.tweak('A/B', status='D ', treeconflict='C', moved_to='A/B2')
@@ -6576,6 +6650,7 @@ test_list = [ None,
               update_removes_switched,
               incomplete_overcomplete,
               update_swapped_depth_dirs,
+              move_update_props,
              ]
 
 if __name__ == '__main__':

Propchange: subversion/branches/verify-keep-going/tools/dist/make-deps-tarball.sh
------------------------------------------------------------------------------
  Merged /subversion/trunk/tools/dist/make-deps-tarball.sh:r1439755-1439797