@Test
public void testParsePartition() throws ROdpsException {

  assertTrue(rodps.formatPartition("pt=1/ds=2", "'", " and ").equals("pt='1' and ds='2'"));
  assertTrue(rodps.formatPartition("pt=1,ds=2", "'", " and ").equals("pt='1' and ds='2'"));
  assertTrue(rodps.formatPartition("pt='1',ds='2'", "'", " and ").equals("pt='1' and ds='2'"));
  assertTrue(rodps.formatPartition("pt=\"1\",ds=\"2\"", "'", " and ").equals(
      "pt='1' and ds='2'"));
  assertTrue(rodps.formatPartition("pt=\"1\",ds=\"2\"", "", ",").equals("pt=1,ds=2"));
  assertTrue(rodps.formatPartition("pt='1',ds='2012-01-01 00:11:11'", "", ",").equals(
      "pt=1,ds=2012-01-01 00:11:11"));
  try {
    assertTrue(rodps.formatPartition("pt='1',ds='a,b'", "", ",").equals(
        "pt=1,ds=2012-01-01 00:11:11"));
    assertTrue(false);
  } catch (Exception e) {
    assertTrue(true);
  }
  try {
    assertTrue(rodps.formatPartition("pt='1',ds='a=b'", "", ",").equals(
        "pt=1,ds=2012-01-01 00:11:11"));
    assertTrue(false);
  } catch (Exception e) {
    assertTrue(true);
  }
  try {
    assertTrue(rodps.formatPartition("pt='1',ds=',a=b'", "", ",").equals(
        "pt=1,ds=2012-01-01 00:11:11"));
    assertTrue(false);
  } catch (Exception e) {
    assertTrue(true);
  }
}