MetaDescriptor { protected static String loadApolloVersion(ClassLoader classLoader) throws IOException { Properties properties = new Properties(); properties.load(classLoader.getResourceAsStream("metaDescriptor.properties")); return properties.getProperty("apolloVersion"); } MetaDescriptor(Descriptor descriptor, String apolloVersion); Descriptor descriptor(); String apolloVersion(); static MetaDescriptor readMetaDescriptor(String serviceName, ClassLoader classLoader);  }
@Test public void testLoadApolloVersion() throws Exception { ClassLoader classLoader = ClassLoader.getSystemClassLoader(); String version = MetaDescriptor.loadApolloVersion(classLoader); assertTrue(version.startsWith("1.")); }