use of org.opendaylight.controller.cluster.datastore.messages.CloseTransaction in project controller by opendaylight.
the class ShardTransactionTest method testReadWriteTxOnReceiveCloseTransaction.
@Test
public void testReadWriteTxOnReceiveCloseTransaction() throws Exception {
new TestKit(getSystem()) {
{
final ActorRef transaction = newTransactionActor(RW, readWriteTransaction(), "testReadWriteTxOnReceiveCloseTransaction");
watch(transaction);
transaction.tell(new CloseTransaction().toSerializable(), getRef());
expectMsgClass(duration("3 seconds"), CloseTransactionReply.class);
expectTerminated(duration("3 seconds"), transaction);
}
};
}
use of org.opendaylight.controller.cluster.datastore.messages.CloseTransaction in project controller by opendaylight.
the class ShardTransactionTest method testWriteOnlyTxOnReceiveCloseTransaction.
@Test
public void testWriteOnlyTxOnReceiveCloseTransaction() throws Exception {
new TestKit(getSystem()) {
{
final ActorRef transaction = newTransactionActor(WO, readWriteTransaction(), "testWriteTxOnReceiveCloseTransaction");
watch(transaction);
transaction.tell(new CloseTransaction().toSerializable(), getRef());
expectMsgClass(duration("3 seconds"), CloseTransactionReply.class);
expectTerminated(duration("3 seconds"), transaction);
}
};
}
use of org.opendaylight.controller.cluster.datastore.messages.CloseTransaction in project controller by opendaylight.
the class ShardTransactionTest method testReadOnlyTxOnReceiveCloseTransaction.
@Test
public void testReadOnlyTxOnReceiveCloseTransaction() throws Exception {
new TestKit(getSystem()) {
{
final ActorRef transaction = newTransactionActor(TransactionType.READ_ONLY, readOnlyTransaction(), "testReadOnlyTxOnReceiveCloseTransaction");
watch(transaction);
transaction.tell(new CloseTransaction().toSerializable(), getRef());
expectMsgClass(duration("3 seconds"), Terminated.class);
}
};
}
Aggregations