VariableFileLineIterator extends AbstractFileLineIterator<T> { @Override public char getEncloseChar() { return encloseChar; } VariableFileLineIterator(String fileName, Class<T> clazz,
            Map<String, ColumnParser> columnParserMap); @Override char getDelimiter(); @Override char getEncloseChar();  }
@Test public void testVariableFileLineIterator01() throws Exception { URL url = this.getClass().getResource("File_Empty.txt"); String fileName = url.getPath(); Class<VariableFileLineIterator_Stub02> clazz = VariableFileLineIterator_Stub02.class; Map<String, ColumnParser> columnParserMap = new HashMap<String, ColumnParser>(); columnParserMap.put("java.lang.String", new NullColumnParser()); VariableFileLineIterator<VariableFileLineIterator_Stub02> variableFileLineIterator = new VariableFileLineIterator<VariableFileLineIterator_Stub02>(fileName, clazz, columnParserMap); assertEquals(fileName, ReflectionTestUtils.getField( variableFileLineIterator, "fileName")); assertSame(clazz, ReflectionTestUtils.getField(variableFileLineIterator, "clazz")); assertSame(columnParserMap, ReflectionTestUtils.getField( variableFileLineIterator, "columnParserMap")); assertEquals('"', variableFileLineIterator.getEncloseChar()); assertEquals('、', variableFileLineIterator.getDelimiter()); }
@Test public void testGetEncloseChar01() throws Exception { URL url = this.getClass().getResource("File_Empty.txt"); String fileName = url.getPath(); Class<VariableFileLineIterator_Stub20> clazz = VariableFileLineIterator_Stub20.class; Map<String, ColumnParser> columnParserMap = new HashMap<String, ColumnParser>(); columnParserMap.put("java.lang.String", new NullColumnParser()); VariableFileLineIterator<VariableFileLineIterator_Stub20> variableFileLineIterator = new VariableFileLineIterator<VariableFileLineIterator_Stub20>(fileName, clazz, columnParserMap); char result = variableFileLineIterator.getEncloseChar(); assertEquals('a', result); }