diff options
author | Brian S. O'Neill <bronee@gmail.com> | 2006-09-03 23:23:51 +0000 |
---|---|---|
committer | Brian S. O'Neill <bronee@gmail.com> | 2006-09-03 23:23:51 +0000 |
commit | f5b0a7c2749afc853a0b7c5b8945ae44120fc4a1 (patch) | |
tree | ff9da44d7324dfb5e0877e028a88cf938f86f262 /src/test/java/com/amazon/carbonado/repo | |
parent | 1e947afa4b660a23a2dcb57463dd810fb73e6030 (diff) |
More tests and fixes.
Diffstat (limited to 'src/test/java/com/amazon/carbonado/repo')
-rw-r--r-- | src/test/java/com/amazon/carbonado/repo/toy/ToyStorage.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/test/java/com/amazon/carbonado/repo/toy/ToyStorage.java b/src/test/java/com/amazon/carbonado/repo/toy/ToyStorage.java index 01f9fbf..84792ad 100644 --- a/src/test/java/com/amazon/carbonado/repo/toy/ToyStorage.java +++ b/src/test/java/com/amazon/carbonado/repo/toy/ToyStorage.java @@ -147,11 +147,16 @@ public class ToyStorage<S extends Storable> implements Storage<S>, MasterSupport try {
for (S existing : mData) {
if (existing.equalPrimaryKeys(storable)) {
+ // Copy altered values to existing object.
existing.markAllPropertiesDirty();
storable.copyAllProperties(existing);
existing.markAllPropertiesClean();
+
+ // Copy all values to user object, to simulate a reload.
+ storable.markAllPropertiesDirty();
existing.copyAllProperties(storable);
storable.markAllPropertiesClean();
+
return true;
}
}
|