### Question:
App { public List<File> getDockerFilesFromGitRepository(String repoPath) { File root = new File(repoPath); String fileName = "Dockerfile"; List<File> rawDockerfiles = new ArrayList<>(); try { boolean recursive = true; Collection files = FileUtils.listFiles(root, null, recursive); for (Iterator iterator = files.iterator(); iterator.hasNext(); ) { File file = (File) iterator.next(); if (file.getName().equals(fileName)) { rawDockerfiles.add(file); } } } catch (Exception e) { e.printStackTrace(); } finally { return rawDockerfiles; } } App(String gitUrl, String gitHubUserName, String gitHubPassword);  App(String gitUrl); static void main(String[] args); List<Dockerfile> getDockerfileObjectsFromRawDockerfiles(List<File> rawDockerfiles); static void createJsonFromProjectObjectAndPrint(Project project, boolean printJson); Dockerfile getDockerfileObjectFromRawDockerfile(File rawDockerfile); void setDiffsBetweenSnapshots(List<Snapshot> snapshots); List<RevCommit> getRevCommitsOfRawDockerfile(String repoFolderNameDotGit, String relativePathToDockerfile); List<Snapshot> getSnapshotsFromRevCommits(List<RevCommit> historyOfFile); Snapshot getFullSnapshotFromRevCommit(RevCommit commit, boolean isCurrent, int index, Repository repository, Git git); List<ChangedFile> getChangedFilesForCommit(RevCommit commit); List<File> getDockerFilesFromGitRepository(String repoPath); String getRelativePathToDockerFile(String absolutePath); File getDockerfileFromCommit(RevCommit revCommit, Repository repository, String dockerPath, String localPath); void init(String gitUrl); Project getProjectFromGitUrl(); final static String LOCAL_REPO_FOLDER; final static String GITAPI; final static String REPOS; static String USERNAME; static String PASSWORD; }### Answer:
@Test public void getRawDockerfilesFromProjectWithRepisitory() throws Exception { App app = appToBeTested; String projectFolderName = app.getProject().getRepositoryPath().replaceAll("/","_"); app.setRepoFolderName(App.LOCAL_REPO_FOLDER + projectFolderName); List<File> rawDockerfiles = app.getDockerFilesFromGitRepository( app.getRepoFolderName()); assertEquals(rawDockerfiles.size(),3); }