list = new PLinkedList<BobContainer>();
BobContainer bobContainer;
bobContainer = new BobContainer();
// store.storedMutableEnum(EnumForTest.VAL1);
Map<EnumKey, Enum<?>> storedEnumMap = new PTreeMap<EnumKey, Enum<?>>();
storedEnumMap.put(new EnumKey(EnumForTest.VAL1), EnumForTest.VAL1);
bobContainer.setObject1(EnumForTest.VAL1);
list.add(bobContainer);
store.setRoot(list, storedEnumMap);
store.save(true, false);
logger.info("second add val1");
list = (PLinkedList<BobContainer>) store.readAndGetRoot();
bobContainer = new BobContainer();
// store.storedMutableEnum(EnumForTest.VAL1);
bobContainer.setObject1(EnumForTest.VAL1);
list.add(bobContainer);
store.save(true, false);
Iterator<BobContainer> iterator;
logger.info("first val1 to val2");
store.readRoot();
list = (PLinkedList<BobContainer>) store.getRoot();
storedEnumMap = store.getStoredEnumMap();
// store.storedMutableEnum(EnumForTest.VAL1);
storedEnumMap.put(new EnumKey(EnumForTest.VAL1), EnumForTest.VAL1);
// store.storedMutableEnum(EnumForTest.VAL2);
storedEnumMap.put(new EnumKey(EnumForTest.VAL2), EnumForTest.VAL2);
iterator = list.iterator();
assertTrue(MUST_HAVE_NEXT_ELEMENT, iterator.hasNext());
bobContainer = iterator.next();
assertEquals(BAD_VALUE, EnumForTest.VAL1, bobContainer.getObject1());
bobContainer.setObject1(EnumForTest.VAL2);