@Test
public void buildMessageShouldReturnSameInteger() {

    final int input = 300;
    Message message = EventPublisher.buildMessage(TEST_CONFIGURATION,
            new ContainsId<Integer>() {
                @Override
                public void setId(Integer id) { }
                @Override
                public Integer getId() {
                    return input;
                }
            }
    );
    int output = message.getBodyAs(Integer.class);
    Assert.assertEquals(input, output);
}