FileSecretHelper implements Function<String, String> { @Override public String apply(String property) { return properties.getProperty(property); } FileSecretHelper(String secretFile); @Override String apply(String property);  }
@Test public void testGetSecret_exists() throws Exception { assertEquals(helper.apply("secret"), "topSecret"); }
@Test public void testGetSecret_not_exists() throws Exception { assertEquals(helper.apply("foo"), null); }