@Test
public void testJoinAndEscapeStrings() throws Exception {

  assertEquals("*!cluster!*!b**o***!xer!oozie**",
      TimelineReaderUtils.joinAndEscapeStrings(
          new String[] {"!cluster", "!b*o*!xer", "oozie*"}, '!', '*'));
  assertEquals("*!cluster!*!b**o***!xer!!",
      TimelineReaderUtils.joinAndEscapeStrings(
          new String[] {"!cluster", "!b*o*!xer", "", ""}, '!', '*'));
  assertNull(TimelineReaderUtils.joinAndEscapeStrings(
      new String[] {"!cluster", "!b*o*!xer", null, ""}, '!', '*'));
}