@Test
public void testPutTake() throws InterruptedException, EventDeliveryException {

  Event event = EventBuilder.withBody("test event".getBytes());
  Context context = new Context();
  Configurables.configure(channel, context);
  Transaction transaction = channel.getTransaction();
  Assert.assertNotNull(transaction);
  transaction.begin();
  channel.put(event);
  transaction.commit();
  transaction.close();
  transaction = channel.getTransaction();
  Assert.assertNotNull(transaction);
  transaction.begin();
  Event event2 = channel.take();
  Assert.assertEquals(event, event2);
  transaction.commit();
}