Path tblPath = new Path(fsLoc, "/tmp/test_pig/data");
String anyExistingFileInCurDir = "ivy.xml";
tblPath.getFileSystem(howlConf).copyFromLocalFile(new Path(anyExistingFileInCurDir),tblPath);
howlDriver.run("drop table junit_pigstorage");
CommandProcessorResponse resp;
String createTable = "create table junit_pigstorage (a string) partitioned by (b string) stored as RCFILE";
resp = howlDriver.run(createTable);
assertEquals(0, resp.getResponseCode());
assertNull(resp.getErrorMessage());
resp = howlDriver.run("alter table junit_pigstorage add partition (b='2010-10-10') location '"+new Path(fsLoc, "/tmp/test_pig")+"'");
assertEquals(0, resp.getResponseCode());
assertNull(resp.getErrorMessage());
resp = howlDriver.run("alter table junit_pigstorage partition (b='2010-10-10') set fileformat inputformat '" + RCFileInputFormat.class.getName()
+"' outputformat '"+RCFileOutputFormat.class.getName()+"' inputdriver '"+PigStorageInputDriver.class.getName()+"' outputdriver 'non-existent'");
assertEquals(0, resp.getResponseCode());
assertNull(resp.getErrorMessage());
resp = howlDriver.run("desc extended junit_pigstorage partition (b='2010-10-10')");
assertEquals(0, resp.getResponseCode());
assertNull(resp.getErrorMessage());
PigServer server = new PigServer(ExecType.LOCAL, howlConf.getAllProperties());
UDFContext.getUDFContext().setClientSystemProps();
server.registerQuery(" a = load 'junit_pigstorage' using "+HowlLoader.class.getName()+";");
Iterator<Tuple> itr = server.openIterator("a");