From 66491cc2d4b35cc62b1cf038ce6cd67554f46024 Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Thu, 1 Apr 2010 17:51:04 +0000 Subject: Update cluster store status with a single atomic write() operation. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@930055 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/tests/StoreStatus.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'cpp/src/tests/StoreStatus.cpp') diff --git a/cpp/src/tests/StoreStatus.cpp b/cpp/src/tests/StoreStatus.cpp index 87b3531236..43d4cfd920 100644 --- a/cpp/src/tests/StoreStatus.cpp +++ b/cpp/src/tests/StoreStatus.cpp @@ -65,7 +65,8 @@ QPID_AUTO_TEST_CASE(testSaveLoadDirty) { Uuid clusterId = Uuid(true); StoreStatus ss(TEST_DIR); ss.load(); - ss.dirty(clusterId); + ss.setClusterId(clusterId); + ss.dirty(); BOOST_CHECK_EQUAL(ss.getState(), STORE_STATE_DIRTY_STORE); StoreStatus ss2(TEST_DIR); @@ -81,7 +82,7 @@ QPID_AUTO_TEST_CASE(testSaveLoadClean) { Uuid shutdownId = Uuid(true); StoreStatus ss(TEST_DIR); ss.load(); - ss.dirty(clusterId); + ss.setClusterId(clusterId); ss.clean(shutdownId); BOOST_CHECK_EQUAL(ss.getState(), STORE_STATE_CLEAN_STORE); @@ -99,9 +100,10 @@ QPID_AUTO_TEST_CASE(testMarkDirty) { Uuid shutdownId = Uuid(true); StoreStatus ss(TEST_DIR); ss.load(); - ss.dirty(clusterId); + ss.setClusterId(clusterId); + ss.dirty(); ss.clean(shutdownId); - ss.dirty(clusterId); + ss.dirty(); StoreStatus ss2(TEST_DIR); ss2.load(); -- cgit v1.2.1