configurationProperties.getProperty( CONFIG_PROPERTY_CLASSPATH ) ); .getProperty( CONFIG_PROPERTY_IGNORE_CLASSES ); String[] ignoredClasses = null; if ( !StringUtil.isEmpty( ignoredClassesProperty ) ) { .getClassLoader(), classpathElements, configurationProperties, ignoredClasses ); verifyClasses( cl, configurationProperties.getProperty( "required.classes" ), configurationProperties.getProperty( "name" ) ); String name = configurationProperties.getProperty( CONFIG_PROPERTY_NAME, id ); registerNativeLibraryPaths( configurationProperties.getProperty( CONFIG_PROPERTY_LIBRARY_PATH ) );
jars = filterJars( jars, configurationProperties.getProperty( CONFIG_PROPERTY_EXCLUDE_JARS ) );
@Test public void testGetPrefixedOsPropertiesLinuxShimConfigFallback() { when( windowsChecker.isWindows() ).thenReturn( false ); shimProperties.setProperty( "java.system.flatclass", "true" ); assertEquals( "true", shimProperties.getProperty( "java.system.flatclass", "false" ) ); }
@Test public void testGetPrefixedOsPropertiesLinuxShimConfigNoBase() { when( windowsChecker.isWindows() ).thenReturn( false ); shimProperties.setProperty( "linux.java.system.flatclass", "true" ); assertEquals( "true", shimProperties.getProperty( "java.system.flatclass", "false" ) ); }
@Test public void testGetPrefixedOsPropertiesLinuxShimConfig() { when( windowsChecker.isWindows() ).thenReturn( false ); shimProperties.setProperty( "java.system.flatclass", "false" ); shimProperties.setProperty( "linux.java.system.flatclass", "true" ); assertEquals( "true", shimProperties.getProperty( "java.system.flatclass" ) ); }
@Test public void testGetPrefixedOsPropertiesWindowsShimConfigTrumpedBySetConfig() { when( windowsChecker.isWindows() ).thenReturn( true ); shimProperties.setProperty( "java.system.flatclass", "false" ); shimProperties.setProperty( "windows.java.system.flatclass", "false" ); shimProperties.setProperty( "mr1.java.system.flatclass", "true" ); shimProperties.setProperty( ShimProperties.SHIM_CP_CONFIG, "mr1" ); assertEquals( "true", shimProperties.getProperty( "java.system.flatclass" ) ); }
@Test public void testGetPrefixedOsPropertiesWindowsAndShimConfigTrumpsWindowsConfig() { when( windowsChecker.isWindows() ).thenReturn( true ); shimProperties.setProperty( "java.system.flatclass", "false" ); shimProperties.setProperty( "windows.java.system.flatclass", "false" ); shimProperties.setProperty( "mr1.java.system.flatclass", "false" ); shimProperties.setProperty( "windows.mr1.java.system.flatclass", "true" ); shimProperties.setProperty( ShimProperties.SHIM_CP_CONFIG, "mr1" ); assertEquals( "true", shimProperties.getProperty( "java.system.flatclass" ) ); } }