@Test
public void testBasic() throws ClassNotFoundException, InstantiationException,
    IllegalAccessException {

  Interceptor.Builder builder = InterceptorBuilderFactory.newInstance(
      InterceptorType.TIMESTAMP.toString());
  Interceptor interceptor = builder.build();
  Event event = EventBuilder.withBody("test event", Charsets.UTF_8);
  Assert.assertNull(event.getHeaders().get(Constants.DEFAULT_HEADER_NAME));
  Long now = System.currentTimeMillis();
  event = interceptor.intercept(event);
  String timestampStr = event.getHeaders().get(Constants.DEFAULT_HEADER_NAME);
  Assert.assertNotNull(timestampStr);
  Assert.assertTrue(Long.parseLong(timestampStr) >= now);
}