Buggy code:
public class TestSolrDiscoveryProperties extends SolrTestCaseJ4 { private static String NEW_LINE = System . getProperty ( "line.separator" ) ; @ BeforeClass public static void beforeClass ( ) throws Exception { } private final File solrHomeDirectory = new File ( TEMP_DIR , ( ( "org.apache.solr.core.TestSolrDiscoveryProperties" + ( File . separator ) ) + "solrHome" ) ) ; private void setMeUp ( ) throws Exception { } private void addSolrPropertiesFile ( String ... extras ) throws Exception { } private void addSolrXml ( ) throws Exception { } private Properties makeCorePropFile ( String name , boolean isLazy , boolean loadOnStartup , String ... extraProps ) { } private void addCoreWithProps ( Properties stockProps ) throws Exception { } private void addConfFiles ( File confDir ) throws Exception { } private void addConfigsForBackCompat ( ) throws Exception { } private CoreContainer init ( ) throws Exception { } @ After public void after ( ) throws Exception { } @ Test public void testPropertiesFile ( ) throws Exception { } @ Test public void testPersistTrue ( ) throws Exception { } @ Test public void testPersistFalse ( ) throws Exception { } void addCoreProps ( SolrCore core , String ... propPairs ) { } void checkSolrProperties ( CoreContainer cc , String ... checkMemPairs ) throws Exception { } void checkCoreProps ( Properties orig , String ... extraProps ) throws Exception { } @ Test public void testBackCompatXml ( ) throws Exception { setMeUp ( ) ; addSolrPropertiesFile ( ) ; addSolrXml ( ) ; addConfigsForBackCompat ( ) ; CoreContainer cc = init ( ) ; try { Properties props = cc . getContainerProperties ( ) ; assertEquals ( "//admin//cores" , cc . getAdminPath ( ) ) ; assertEquals ( "collectionLazy2" , cc . getDefaultCoreName ( ) ) ; assertNull ( props . getProperty ( "cores.adminPath" ) ) ; assertNull ( props . getProperty ( "cores.defaultCoreName" ) ) ; assertNull ( props . getProperty ( "host" ) ) ; assertNull ( props . getProperty ( "port" ) ) ; assertNull ( props . getProperty ( "cores.hostContext" ) ) ; assertNull ( props . getProperty ( "cores.zkClientTimeout" ) ) ; SolrCore core1 = cc . getCore ( "collection1" ) ; CoreDescriptor desc = core1 . getCoreDescriptor ( ) ; assertEquals ( "collection1" , desc . getProperty ( "solr.core.name" ) ) ; assertNotNull ( desc . getProperty ( "solr.core.instanceDir" ) ) ; <START_BUG> assertEquals ( "data//" , desc . getProperty ( "solr.core.dataDir" ) ) ; <END_BUG> assertEquals ( "solrconfig-minimal.xml" , desc . getProperty ( "solr.core.configName" ) ) ; assertEquals ( "schema-tiny.xml" , desc . getProperty ( "solr.core.schemaName" ) ) ; core1 . close ( ) ; } finally { cc . shutdown ( ) ; } } private static final String SOLR_PROPERTIES = ( ( ( ( ( ( ( ( ( ( ( ( ( "persistent=${persistent:false}" + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "cores.adminPath=//admin//cores//props" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "cores.defaultCoreName=defcore" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "host=222.333.444.555" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "port=6000" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "cores.hostContext=//solrprop" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "cores.zkClientTimeout=20" ) + ( TestSolrDiscoveryProperties . NEW_LINE ) ) + "cores.transientCacheSize=2" ; private static final String SOLR_XML = "<seq2seq4repair_space><solr<seq2seq4repair_space>persistent=\"false\"><seq2seq4repair_space>" + ( ( ( "<cores<seq2seq4repair_space>adminPath=\"//admin//cores\"<seq2seq4repair_space>defaultCoreName=\"collectionLazy2\"<seq2seq4repair_space>transientCacheSize=\"4\"><seq2seq4repair_space>" + "<core<seq2seq4repair_space>name=\"collection1\"<seq2seq4repair_space>instanceDir=\"collection1\"<seq2seq4repair_space>config=\"solrconfig-minimal.xml\"<seq2seq4repair_space>schema=\"schema-tiny.xml\"<seq2seq4repair_space>//><seq2seq4repair_space>" ) + "<//cores><seq2seq4repair_space>" ) + "<//solr>" ) ; }

Fix:
assertEquals ( ( "data" + ( File . separator ) ) , desc . getProperty ( "solr.core.dataDir" ) ) ;