summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Nieder <jrn@google.com>2015-05-21 16:15:06 -0700
committerJonathan Nieder <jrn@google.com>2015-05-21 16:15:06 -0700
commitadbcbc791b854071f0d2ca60a85832a025982ef8 (patch)
treebdd85f7e6516f53a17118a9bb1406ba966093f0c
parent686124bec32fcdee1545e7d9c312dcf0276b44af (diff)
downloadjgit-adbcbc791b854071f0d2ca60a85832a025982ef8.tar.gz
jgit-adbcbc791b854071f0d2ca60a85832a025982ef8.zip
Expose Sets helper to tests outside org.eclipse.jgit.api
A later patch will make use of this class in a org.eclipse.jgit.lib test. Change-Id: I2b268e6a5dbf12174201f45259f9f007686708d2 Signed-off-by: Jonathan Nieder <jrn@google.com>
-rw-r--r--org.eclipse.jgit.test/pom.xml1
-rw-r--r--org.eclipse.jgit.test/src/org/eclipse/jgit/lib/Sets.java (renamed from org.eclipse.jgit.test/tst/org/eclipse/jgit/api/Sets.java)6
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/api/MergeCommandTest.java1
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StatusCommandTest.java1
4 files changed, 6 insertions, 3 deletions
diff --git a/org.eclipse.jgit.test/pom.xml b/org.eclipse.jgit.test/pom.xml
index 0e1419a161..da700939c0 100644
--- a/org.eclipse.jgit.test/pom.xml
+++ b/org.eclipse.jgit.test/pom.xml
@@ -102,6 +102,7 @@
</dependencies>
<build>
+ <sourceDirectory>src/</sourceDirectory>
<testSourceDirectory>tst/</testSourceDirectory>
<testResources>
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/Sets.java b/org.eclipse.jgit.test/src/org/eclipse/jgit/lib/Sets.java
index edfab551ab..731685731b 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/Sets.java
+++ b/org.eclipse.jgit.test/src/org/eclipse/jgit/lib/Sets.java
@@ -41,13 +41,13 @@
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-package org.eclipse.jgit.api;
+package org.eclipse.jgit.lib;
import java.util.HashSet;
import java.util.Set;
-class Sets {
- static <T> Set<T> of(T... elements) {
+public class Sets {
+ public static <T> Set<T> of(T... elements) {
Set<T> ret = new HashSet<T>();
for (T element : elements)
ret.add(element);
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/MergeCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/MergeCommandTest.java
index 761aafa3f9..0c0c6e5b55 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/MergeCommandTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/MergeCommandTest.java
@@ -62,6 +62,7 @@ import org.eclipse.jgit.lib.Constants;
import org.eclipse.jgit.lib.Ref;
import org.eclipse.jgit.lib.Repository;
import org.eclipse.jgit.lib.RepositoryState;
+import org.eclipse.jgit.lib.Sets;
import org.eclipse.jgit.merge.MergeStrategy;
import org.eclipse.jgit.merge.ResolveMerger.MergeFailureReason;
import org.eclipse.jgit.revwalk.RevCommit;
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StatusCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StatusCommandTest.java
index 47650232b3..c70604ecb4 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StatusCommandTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StatusCommandTest.java
@@ -53,6 +53,7 @@ import org.eclipse.jgit.api.errors.GitAPIException;
import org.eclipse.jgit.api.errors.NoFilepatternException;
import org.eclipse.jgit.errors.NoWorkTreeException;
import org.eclipse.jgit.junit.RepositoryTestCase;
+import org.eclipse.jgit.lib.Sets;
import org.junit.Test;
public class StatusCommandTest extends RepositoryTestCase {