SystemSettingsConfiguration implements IConfiguration { @Override public Properties getProperties() throws IOException { Properties props = new Properties(); List elements = settings.getSystemSettings( "pentaho-system" ); if ( elements == null ) { return null; } elements = ( (Element) elements.get( 0 ) ).content(); addElementsToProperties( elements, props, "" ); return props; } SystemSettingsConfiguration( String id, ISystemSettings settings ); @Override String getId(); @Override Properties getProperties(); @Override void update( Properties properties );  }
@Test public void testGetProperties() throws Exception { SystemSettings settings = new SystemSettings(); IApplicationContext appContext = mock( IApplicationContext.class ); PentahoSystem.setApplicationContext( appContext ); when( appContext.getSolutionPath( anyString() ) ).thenReturn( TestResourceLocation.TEST_RESOURCES + "/solution/system/pentaho.xml" ); config = new SystemSettingsConfiguration( "system", settings ); Properties properties = config.getProperties(); assertNotNull( properties ); assertEquals( "DEBUG", properties.getProperty( "log-level" ) ); }