@Test void getLocalPathWhenContentProvided() { String fileName = configFileService.getLocalPathForContents(TEST_FILE_CONTENTS, TEST_FILE_NAME); assertThat(fileName).isEqualTo(TEST_FILE_PATH); }
public String getLocalPathForContents(String contents, String path) { if (StringUtils.isNotEmpty(contents)) { return ConfigFileUtils.writeToTempFile(contents, path); } return null; }
ConfigFileService { public String getLocalPathForContents(String contents, String path) { if (StringUtils.isNotEmpty(contents)) { return ConfigFileUtils.writeToTempFile(contents, path); } return null; } }
ConfigFileService { public String getLocalPathForContents(String contents, String path) { if (StringUtils.isNotEmpty(contents)) { return ConfigFileUtils.writeToTempFile(contents, path); } return null; } ConfigFileService(CloudConfigResourceService cloudConfigResourceService); }
ConfigFileService { public String getLocalPathForContents(String contents, String path) { if (StringUtils.isNotEmpty(contents)) { return ConfigFileUtils.writeToTempFile(contents, path); } return null; } ConfigFileService(CloudConfigResourceService cloudConfigResourceService); String getLocalPath(String path); String getLocalPathForContents(String contents, String path); String getContents(String path); }
ConfigFileService { public String getLocalPathForContents(String contents, String path) { if (StringUtils.isNotEmpty(contents)) { return ConfigFileUtils.writeToTempFile(contents, path); } return null; } ConfigFileService(CloudConfigResourceService cloudConfigResourceService); String getLocalPath(String path); String getLocalPathForContents(String contents, String path); String getContents(String path);  }