aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java')
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java25
1 files changed, 7 insertions, 18 deletions
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java
index 3087ca829b..f16d436d94 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ResetCommandTest.java
@@ -54,12 +54,8 @@ import java.io.IOException;
import java.io.PrintWriter;
import org.eclipse.jgit.api.ResetCommand.ResetType;
-import org.eclipse.jgit.api.errors.ConcurrentRefUpdateException;
+import org.eclipse.jgit.api.errors.GitAPIException;
import org.eclipse.jgit.api.errors.JGitInternalException;
-import org.eclipse.jgit.api.errors.NoFilepatternException;
-import org.eclipse.jgit.api.errors.NoHeadException;
-import org.eclipse.jgit.api.errors.NoMessageException;
-import org.eclipse.jgit.api.errors.WrongRepositoryStateException;
import org.eclipse.jgit.dircache.DirCache;
import org.eclipse.jgit.dircache.DirCacheEntry;
import org.eclipse.jgit.errors.AmbiguousObjectException;
@@ -87,9 +83,8 @@ public class ResetCommandTest extends RepositoryTestCase {
private DirCacheEntry prestage;
- public void setupRepository() throws IOException, NoFilepatternException,
- NoHeadException, NoMessageException, ConcurrentRefUpdateException,
- JGitInternalException, WrongRepositoryStateException {
+ public void setupRepository() throws IOException, JGitInternalException,
+ GitAPIException {
// create initial commit
git = new Git(db);
@@ -138,9 +133,7 @@ public class ResetCommandTest extends RepositoryTestCase {
@Test
public void testHardReset() throws JGitInternalException,
- AmbiguousObjectException, IOException, NoFilepatternException,
- NoHeadException, NoMessageException, ConcurrentRefUpdateException,
- WrongRepositoryStateException {
+ AmbiguousObjectException, IOException, GitAPIException {
setupRepository();
ObjectId prevHead = db.resolve(Constants.HEAD);
git.reset().setMode(ResetType.HARD).setRef(initialCommit.getName())
@@ -160,7 +153,7 @@ public class ResetCommandTest extends RepositoryTestCase {
@Test
public void testResetToNonexistingHEAD() throws JGitInternalException,
- AmbiguousObjectException, IOException {
+ AmbiguousObjectException, IOException, GitAPIException {
// create a file in the working tree of a fresh repo
git = new Git(db);
@@ -176,9 +169,7 @@ public class ResetCommandTest extends RepositoryTestCase {
@Test
public void testSoftReset() throws JGitInternalException,
- AmbiguousObjectException, IOException, NoFilepatternException,
- NoHeadException, NoMessageException, ConcurrentRefUpdateException,
- WrongRepositoryStateException {
+ AmbiguousObjectException, IOException, GitAPIException {
setupRepository();
ObjectId prevHead = db.resolve(Constants.HEAD);
git.reset().setMode(ResetType.SOFT).setRef(initialCommit.getName())
@@ -198,9 +189,7 @@ public class ResetCommandTest extends RepositoryTestCase {
@Test
public void testMixedReset() throws JGitInternalException,
- AmbiguousObjectException, IOException, NoFilepatternException,
- NoHeadException, NoMessageException, ConcurrentRefUpdateException,
- WrongRepositoryStateException {
+ AmbiguousObjectException, IOException, GitAPIException {
setupRepository();
ObjectId prevHead = db.resolve(Constants.HEAD);
git.reset().setMode(ResetType.MIXED).setRef(initialCommit.getName())