use of com.hazelcast.collection.IList in project hazelcast by hazelcast.
the class ClientTxnListTest method testAddAndRoleBack.
@Test
public void testAddAndRoleBack() throws Exception {
final String listName = randomString();
final IList l = client.getList(listName);
l.add("item1");
final TransactionContext context = client.newTransactionContext();
context.beginTransaction();
final TransactionalList<Object> list = context.getList(listName);
list.add("item2");
context.rollbackTransaction();
assertEquals(1, l.size());
}
use of com.hazelcast.collection.IList in project hazelcast by hazelcast.
the class MBeanDestroyTest method testList.
@Test
public void testList() throws Exception {
IList list = holder.getHz().getList("list");
list.size();
holder.assertMBeanExistEventually("IList", list.getName());
destroyObjectAndAssert(list, "IList");
}
Aggregations