for (int i=0; i < 5; i++) {
String content = "This is test " + i;
conn.publish(new MsgUnit(pubKey, content.getBytes(), pubQos));
}
int ret = msgInterceptor.waitOnUpdate(3000L, 1);
assertEquals("We expected one message for the excess of the history queue", 1, ret);
msgInterceptor.clear();
for (int i=5; i < 8; i++) {
String content = "This is test " + i;
conn.publish(new MsgUnit(pubKey, content.getBytes(), pubQos));