@Test public void test() throws IOException { Properties props = ResourceUtils.getResource("properties/saturn-core-test.properties"); assertThat(props.getProperty("build.version.test")).isEqualTo("saturn-dev-test"); }
public static Properties getResource(String resource) throws IOException { Properties props = new Properties(); InputStream is = null; try { is = ResourceUtils.class.getClassLoader().getResourceAsStream(resource); if (is != null) { props.load(is); } } finally { if (is != null) { is.close(); } } return props; }
ResourceUtils { public static Properties getResource(String resource) throws IOException { Properties props = new Properties(); InputStream is = null; try { is = ResourceUtils.class.getClassLoader().getResourceAsStream(resource); if (is != null) { props.load(is); } } finally { if (is != null) { is.close(); } } return props; } }
ResourceUtils { public static Properties getResource(String resource) throws IOException { Properties props = new Properties(); InputStream is = null; try { is = ResourceUtils.class.getClassLoader().getResourceAsStream(resource); if (is != null) { props.load(is); } } finally { if (is != null) { is.close(); } } return props; }  }
ResourceUtils { public static Properties getResource(String resource) throws IOException { Properties props = new Properties(); InputStream is = null; try { is = ResourceUtils.class.getClassLoader().getResourceAsStream(resource); if (is != null) { props.load(is); } } finally { if (is != null) { is.close(); } } return props; }  static Properties getResource(String resource); }
ResourceUtils { public static Properties getResource(String resource) throws IOException { Properties props = new Properties(); InputStream is = null; try { is = ResourceUtils.class.getClassLoader().getResourceAsStream(resource); if (is != null) { props.load(is); } } finally { if (is != null) { is.close(); } } return props; }  static Properties getResource(String resource);  }