@Test public void testReadyToCommitNewFiles() throws IOException, JavaGitException { List<File> filesToAdd = new ArrayList<File>(); filesToAdd.add(file1); filesToAdd.add(file2); filesToAdd.add(new File("testDirectory")); filesToAdd.add(new File( "testDirectory" + File.separator + file3.getPath())); GitAddOptions addOptions = new GitAddOptions(); gitAdd.add(repositoryDirectory, addOptions, filesToAdd); List<File> statusPath = null; GitStatusResponse status = gitStatus.status(repositoryDirectory, options, statusPath); int noOfNewFilesToCommit = status.getNewFilesToCommitSize(); assertEquals("Error. No of New Files to commit does not match", 3, noOfNewFilesToCommit); assertEquals("Error. Filename does not match", "foobar01", status .getFileFromNewFilesToCommit(0).getName()); assertEquals("Error. Filename does not match", "foobar02", status .getFileFromNewFilesToCommit(1).getName()); assertEquals("Error. Filename does not match", repositoryDirectory.getPath() + File.separator + "testDirectory" + File.separator + "foobar03", status.getFileFromNewFilesToCommit(2).toString()); }
public GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths) throws JavaGitException, IOException { CheckUtilities.checkFileValidity(repositoryPath); IClient client = ClientManager.getInstance().getPreferredClient(); IGitStatus gitStatus = client.getGitStatusInstance(); return gitStatus.status(repositoryPath, options, paths); }
GitStatus { public GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths) throws JavaGitException, IOException { CheckUtilities.checkFileValidity(repositoryPath); IClient client = ClientManager.getInstance().getPreferredClient(); IGitStatus gitStatus = client.getGitStatusInstance(); return gitStatus.status(repositoryPath, options, paths); } }
GitStatus { public GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths) throws JavaGitException, IOException { CheckUtilities.checkFileValidity(repositoryPath); IClient client = ClientManager.getInstance().getPreferredClient(); IGitStatus gitStatus = client.getGitStatusInstance(); return gitStatus.status(repositoryPath, options, paths); }  }
GitStatus { public GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths) throws JavaGitException, IOException { CheckUtilities.checkFileValidity(repositoryPath); IClient client = ClientManager.getInstance().getPreferredClient(); IGitStatus gitStatus = client.getGitStatusInstance(); return gitStatus.status(repositoryPath, options, paths); }  GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths); GitStatusResponse status(File repositoryPath, List<File> paths); GitStatusResponse status(File repositoryPath, GitStatusOptions options); GitStatusResponse status(File repositoryPath, GitStatusOptions options, File file); GitStatusResponse status(File repositoryPath); GitStatusResponse statusAll(File repositoryPath); GitStatusResponse getSingleFileStatus(File repositoryPath, File path); GitFileSystemObject.Status getFileStatus(File repositoryPath, File path); }
GitStatus { public GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths) throws JavaGitException, IOException { CheckUtilities.checkFileValidity(repositoryPath); IClient client = ClientManager.getInstance().getPreferredClient(); IGitStatus gitStatus = client.getGitStatusInstance(); return gitStatus.status(repositoryPath, options, paths); }  GitStatusResponse status(File repositoryPath, GitStatusOptions options, List<File> paths); GitStatusResponse status(File repositoryPath, List<File> paths); GitStatusResponse status(File repositoryPath, GitStatusOptions options); GitStatusResponse status(File repositoryPath, GitStatusOptions options, File file); GitStatusResponse status(File repositoryPath); GitStatusResponse statusAll(File repositoryPath); GitStatusResponse getSingleFileStatus(File repositoryPath, File path); GitFileSystemObject.Status getFileStatus(File repositoryPath, File path);  }