summaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.pgm.test/tst
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.jgit.pgm.test/tst')
-rw-r--r--org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java11
1 files changed, 4 insertions, 7 deletions
diff --git a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java
index 03391a0fb6..d38a41dcb8 100644
--- a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java
+++ b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java
@@ -43,10 +43,11 @@
package org.eclipse.jgit.pgm;
import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
import org.eclipse.jgit.api.Git;
import org.eclipse.jgit.lib.CLIRepositoryTestCase;
-import org.eclipse.jgit.lib.Ref;
import org.junit.Before;
import org.junit.Test;
@@ -75,13 +76,9 @@ public class TagTest extends CLIRepositoryTestCase {
@Test
public void testTagDelete() throws Exception {
git.tag().setName("test").call();
-
- Ref ref = git.getRepository().getTags().get("test");
- assertEquals("refs/tags/test", ref.getName());
-
+ assertNotNull(git.getRepository().exactRef("refs/tags/test"));
assertEquals("", executeUnchecked("git tag -d test")[0]);
- Ref deletedRef = git.getRepository().getTags().get("test");
- assertEquals(null, deletedRef);
+ assertNull(git.getRepository().exactRef("refs/tags/test"));
}
@Test