File addedFile = writeTrashFile(addedPath, "content2");
git.add().addFilepattern(addedPath).call();
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertFalse(addedFile.exists());
public void indexDelete() throws Exception {
git.rm().addFilepattern("file.txt").call();
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(committedFile));
public void workingDirectoryModify() throws Exception {
writeTrashFile("file.txt", "content2");
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(committedFile));
writeTrashFile(path, "content2");
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(subfolderFile));
git.add().addFilepattern("file.txt").call();
writeTrashFile("file.txt", "content3");
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(committedFile));
git.add().addFilepattern("file.txt").call();
writeTrashFile("file.txt", "content");
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(committedFile));
FileUtils.delete(added);
assertFalse(added.exists());
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertFalse(added.exists());
FileUtils.delete(committedFile);
assertFalse(committedFile.exists());
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertEquals("content", read(committedFile));
File addedFile = writeTrashFile(addedPath, "content2");
git.add().addFilepattern(addedPath).call();
- RevCommit stashed = Git.wrap(db).stashCreate().call();
+ RevCommit stashed = git.stashCreate().call();
assertNotNull(stashed);
assertTrue(committedFile.exists());
assertFalse(addedFile.exists());