@Test
public void testDecodeArray() {

  Assert.assertTrue(TempletonUtils.encodeArray((String[]) null) == null);
  String[] tmp = new String[3];
  tmp[0] = "fred";
  tmp[1] = null;
  tmp[2] = "peter,lisa,, barney";
  String[] tmp2 = TempletonUtils.decodeArray(TempletonUtils.encodeArray(tmp));
  try {
    for (int i=0; i< tmp.length; i++) {
      Assert.assertEquals((String) tmp[i], (String)tmp2[i]);
    }
  } catch (Exception e) {
    Assert.fail("Arrays were not equal" + e.getMessage());
  }
}