Buggy code:
public class TestVariableResolverEndToEnd extends AbstractDIHJdbcTestCase { @ Test public void test ( ) throws Exception { } @ Override protected String generateConfig ( ) { String thirdLocaleParam = ( random ( ) . nextBoolean ( ) ) ? "" : ( ",<seq2seq4repair_space>'" + ( Locale . getDefault ( ) ) ) + "'" ; StringBuilder sb = new StringBuilder ( ) ; sb . append ( "<dataConfig><seq2seq4repair_space>\n" ) ; <START_BUG> sb . append ( "<dataSource<seq2seq4repair_space>name=\"hsqldb\"<seq2seq4repair_space>driver=\"org.hsqldb.jdbcDriver\"<seq2seq4repair_space>url=\"jdbc:hsqldb:mem:.\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ; <END_BUG> sb . append ( "<document<seq2seq4repair_space>name=\"TestEvaluators\"><seq2seq4repair_space>\n" ) ; sb . append ( "<entity<seq2seq4repair_space>name=\"FIRST\"<seq2seq4repair_space>processor=\"SqlEntityProcessor\"<seq2seq4repair_space>dataSource=\"hsqldb\"<seq2seq4repair_space>" ) ; sb . append ( ( "<seq2seq4repair_space>query=\"" + ( ( ( ( "select<seq2seq4repair_space>" + "<seq2seq4repair_space>1<seq2seq4repair_space>as<seq2seq4repair_space>id,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'SELECT'<seq2seq4repair_space>as<seq2seq4repair_space>SELECT_KEYWORD,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>CURRENT_TIMESTAMP<seq2seq4repair_space>as<seq2seq4repair_space>FIRST_TS<seq2seq4repair_space>" ) + "from<seq2seq4repair_space>DUAL<seq2seq4repair_space>\"<seq2seq4repair_space>>\n" ) ) ) ; sb . append ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"SELECT_KEYWORD\"<seq2seq4repair_space>name=\"select_keyword_s\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ; sb . append ( "<seq2seq4repair_space><entity<seq2seq4repair_space>name=\"SECOND\"<seq2seq4repair_space>processor=\"SqlEntityProcessor\"<seq2seq4repair_space>dataSource=\"hsqldb\"<seq2seq4repair_space>transformer=\"TemplateTransformer\"<seq2seq4repair_space>" ) ; sb . append ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( "<seq2seq4repair_space>query=\"" + ( ( ( "${dataimporter.functions.encodeUrl(FIRST.SELECT_KEYWORD)}<seq2seq4repair_space>" + "<seq2seq4repair_space>1<seq2seq4repair_space>as<seq2seq4repair_space>SORT,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>CURRENT_TIMESTAMP<seq2seq4repair_space>as<seq2seq4repair_space>SECOND_TS,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'${dataimporter.functions.formatDate(FIRST.FIRST_TS,<seq2seq4repair_space>'yyyy'" ) ) + thirdLocaleParam ) + ")}'<seq2seq4repair_space>as<seq2seq4repair_space>SECOND1_S,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'PORK'<seq2seq4repair_space>AS<seq2seq4repair_space>MEAT,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'GRILL'<seq2seq4repair_space>AS<seq2seq4repair_space>METHOD,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'ROUND'<seq2seq4repair_space>AS<seq2seq4repair_space>CUTS,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'BEEF_CUTS'<seq2seq4repair_space>AS<seq2seq4repair_space>WHATKIND<seq2seq4repair_space>" ) + "from<seq2seq4repair_space>DUAL<seq2seq4repair_space>" ) + "WHERE<seq2seq4repair_space>1=${FIRST.ID}<seq2seq4repair_space>" ) + "UNION<seq2seq4repair_space>" ) + "${dataimporter.functions.encodeUrl(FIRST.SELECT_KEYWORD)}<seq2seq4repair_space>" ) + "<seq2seq4repair_space>2<seq2seq4repair_space>as<seq2seq4repair_space>SORT,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>CURRENT_TIMESTAMP<seq2seq4repair_space>as<seq2seq4repair_space>SECOND_TS,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'${dataimporter.functions.formatDate(FIRST.FIRST_TS,<seq2seq4repair_space>'yyyy'" ) + thirdLocaleParam ) + ")}'<seq2seq4repair_space>as<seq2seq4repair_space>SECOND1_S,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'FISH'<seq2seq4repair_space>AS<seq2seq4repair_space>MEAT,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'FRY'<seq2seq4repair_space>AS<seq2seq4repair_space>METHOD,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'SIRLOIN'<seq2seq4repair_space>AS<seq2seq4repair_space>CUTS,<seq2seq4repair_space>" ) + "<seq2seq4repair_space>'BEEF_CUTS'<seq2seq4repair_space>AS<seq2seq4repair_space>WHATKIND<seq2seq4repair_space>" ) + "from<seq2seq4repair_space>DUAL<seq2seq4repair_space>" ) + "WHERE<seq2seq4repair_space>1=${FIRST.ID}<seq2seq4repair_space>" ) + "ORDER<seq2seq4repair_space>BY<seq2seq4repair_space>SORT<seq2seq4repair_space>\"" ) + ">\n" ) ) ; sb . append ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"SECOND_S\"<seq2seq4repair_space>name=\"second_s\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ; sb . append ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"SECOND1_S\"<seq2seq4repair_space>name=\"second1_s\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ; sb . append ( ( ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"second2_s\"<seq2seq4repair_space>template=\"${dataimporter.functions.formatDate(SECOND.SECOND_TS,<seq2seq4repair_space>\'yyyy\'" + thirdLocaleParam ) + ")}\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ) ; sb . append ( ( ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"second3_s\"<seq2seq4repair_space>template=\"${dih.functions.formatDate(SECOND.SECOND_TS,<seq2seq4repair_space>\'yyyy\'" + thirdLocaleParam ) + ")}\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ) ; sb . append ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"METHOD\"<seq2seq4repair_space>name=\"${SECOND.MEAT}_s\"//>\n" ) ; sb . append ( "<seq2seq4repair_space><field<seq2seq4repair_space>column=\"CUTS\"<seq2seq4repair_space>name=\"${SECOND.WHATKIND}_mult_s\"//>\n" ) ; sb . append ( "<seq2seq4repair_space><//entity>\n" ) ; sb . append ( "<//entity>\n" ) ; sb . append ( "<//document><seq2seq4repair_space>\n" ) ; sb . append ( "<//dataConfig><seq2seq4repair_space>\n" ) ; String config = sb . toString ( ) ; log . debug ( config ) ; return config ; } @ Override protected void populateData ( Connection conn ) throws Exception { } @ Override protected Database setAllowedDatabases ( ) { } }

Fix:
sb . append ( "<dataSource<seq2seq4repair_space>name=\"hsqldb\"<seq2seq4repair_space>driver=\"${dataimporter.request.dots.in.hsqldb.driver}\"<seq2seq4repair_space>url=\"jdbc:hsqldb:mem:.\"<seq2seq4repair_space>//><seq2seq4repair_space>\n" ) ;