### Question:
CSVFileSchemaParser implements FileSchemaParser { public void setSeparatorChar(String separatorChar) { this.separatorChar = separatorChar; }  @Override Schema parse(InputStream is, Charset charset, TableSchemaType target); TableSettings parseTableSettings(InputStream is, Charset charset, TableSchemaType target); boolean tableSettingsRequireFileInspection(); @Override TableSettings deriveTableSettings(TableSchemaType target); String deriveHiveRecordFormat(); void setAutoDetect(boolean autoDetect); void setHeaderRow(boolean headerRow); void setNumRowsToSample(int numRowsToSample); String getSeparatorChar(); void setSeparatorChar(String separatorChar); String getQuoteChar(); void setQuoteChar(String quoteChar); String getEscapeChar(); void setEscapeChar(String escapeChar);  }### Answer:
@Test public void testSemiColonCSVWithEscapeParse() throws Exception { parser.setSeparatorChar(";"); validateSchema1("col1;col2;col3\nr1v1;r1v2;r1v3\nr2v1;r2v2;r2v3\n"); }
@Test public void testTildeCSVWithEscapeParse() throws Exception { parser.setSeparatorChar("~"); validateSchema1("col1~col2~col3\nr1v1~r1v2~r1v3\nr2v1~r2v2~r2v3\n"); }
@Test public void testSemiColonTSVWithEscapeParse() throws Exception { parser.setSeparatorChar("\t"); validateSchema1("col1\tcol2\tcol3\nr1v1\tr1v2\tr1v3\nr2v1\tr2v2\tr2v3\n"); }
@Test public void testSparse() throws Exception { parser.setSeparatorChar("\t"); try { validateSchema1("col1\tcol2\tcol3\nr1v1\tr1v2\tr1v3\tr1v4\nr2v1\tr2v2\tr2v3\n"); fail("Expecting unrecognized format"); } catch (IOException e) { checkInvalidFormatException(e); } }