subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hwri...@apache.org
Subject svn commit: r1161168 - /subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c
Date Wed, 24 Aug 2011 15:47:12 GMT
Author: hwright
Date: Wed Aug 24 15:47:11 2011
New Revision: 1161168

URL: http://svn.apache.org/viewvc?rev=1161168&view=rev
Log:
On the revprop-packing branch:
Fix the pack notify test expectations to handle revprop packing notifications.

* subversion/tests/libsvn_fs_fs/fs-pack-test.c
  (pack_notify): Reset the expectation when starting to pack revprops, and
    update the expectation state machine for revprop packing.

Modified:
    subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c

Modified: subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c
URL: http://svn.apache.org/viewvc/subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c?rev=1161168&r1=1161167&r2=1161168&view=diff
==============================================================================
--- subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c (original)
+++ subversion/branches/revprop-packing/subversion/tests/libsvn_fs_fs/fs-pack-test.c Wed Aug
24 15:47:11 2011
@@ -109,6 +109,14 @@ pack_notify(void *baton,
 {
   struct pack_notify_baton *pnb = baton;
 
+  if (shard == 0 && action == svn_fs_pack_notify_start_revprop)
+    {
+      /* In this case, we've started packing revprops, so reset our
+         expectations. */
+      pnb->expected_shard = 0;
+      pnb->expected_action = svn_fs_pack_notify_start_revprop;
+    }
+
   SVN_TEST_ASSERT(shard == pnb->expected_shard);
   SVN_TEST_ASSERT(action == pnb->expected_action);
 
@@ -124,6 +132,15 @@ pack_notify(void *baton,
         pnb->expected_shard++;
         break;
 
+      case svn_fs_pack_notify_start_revprop:
+        pnb->expected_action = svn_fs_pack_notify_end_revprop;
+        break;
+
+      case svn_fs_pack_notify_end_revprop:
+        pnb->expected_action = svn_fs_pack_notify_start_revprop;
+        pnb->expected_shard++;
+        break;
+
       default:
         return svn_error_create(SVN_ERR_TEST_FAILED, NULL,
                                 "Unknown notification action when packing");



Mime
View raw message