diff options
author | Matthias Sohn <matthias.sohn@sap.com> | 2014-03-05 02:02:03 +0100 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2014-03-05 02:02:16 +0100 |
commit | 71b90400bb5e91050941844156ec548211bbb447 (patch) | |
tree | f5d768c0373e0700d87ec010bd717c4869797ad6 /org.eclipse.jgit.test | |
parent | b640e3ab319ca6bf4310d2a1e681e4a08f5ddd50 (diff) | |
parent | f59b680c4c0edd257b4777932bdb2cc2de1db797 (diff) | |
download | jgit-71b90400bb5e91050941844156ec548211bbb447.tar.gz jgit-71b90400bb5e91050941844156ec548211bbb447.zip |
Merge branch 'stable-3.3'
* stable-3.3:
Update scripts to deploy jgit on Maven central
Prepare 3.3.1-SNAPSHOT builds
JGit v3.3.0.201403021825-r
Fix merge/cherry-picking in CRLF mode
Expose the received pack size in ReceivePack
Revert "Add getPackFile to ReceivePack to make PostReceiveHook more usable"
Avoid an NPE after 7b01a5369210
Add a launcher for Java 7 tests
Remove obsolete getRepositoryMethod from WorkingTreeIterator
Fix NPE when WorkingTreeIterator does not have a repository set
Add getPackFile to ReceivePack to make PostReceiveHook more usable
Possibility to limit the max pack size on receive-pack
Package httpclient and httpcore in o.e.j.http.apache.feature
Change-Id: I814a150980854bbaabd767f97b062d247af6cb50
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit.test')
-rw-r--r-- | org.eclipse.jgit.test/META-INF/MANIFEST.MF | 72 | ||||
-rw-r--r-- | org.eclipse.jgit.test/pom.xml | 2 | ||||
-rw-r--r-- | org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/ResolveMergerTest.java | 32 |
3 files changed, 69 insertions, 37 deletions
diff --git a/org.eclipse.jgit.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.test/META-INF/MANIFEST.MF index 5453184246..3f2f6ca013 100644 --- a/org.eclipse.jgit.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.test/META-INF/MANIFEST.MF @@ -2,47 +2,47 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %plugin_name Bundle-SymbolicName: org.eclipse.jgit.test -Bundle-Version: 3.3.0.qualifier +Bundle-Version: 3.3.1.qualifier Bundle-Localization: plugin Bundle-Vendor: %provider_name Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: J2SE-1.5 Import-Package: com.googlecode.javaewah;version="[0.7.9,0.8.0)", - org.eclipse.jgit.api;version="[3.3.0,3.4.0)", - org.eclipse.jgit.api.errors;version="[3.3.0,3.4.0)", - org.eclipse.jgit.awtui;version="[3.3.0,3.4.0)", - org.eclipse.jgit.blame;version="[3.3.0,3.4.0)", - org.eclipse.jgit.console;version="[3.3.0,3.4.0)", - org.eclipse.jgit.diff;version="[3.3.0,3.4.0)", - org.eclipse.jgit.dircache;version="[3.3.0,3.4.0)", - org.eclipse.jgit.errors;version="[3.3.0,3.4.0)", - org.eclipse.jgit.events;version="[3.3.0,3.4.0)", - org.eclipse.jgit.fnmatch;version="[3.3.0,3.4.0)", - org.eclipse.jgit.ignore;version="[3.3.0,3.4.0)", - org.eclipse.jgit.internal;version="[3.3.0,3.4.0)", - org.eclipse.jgit.internal.storage.dfs;version="[3.3.0,3.4.0)", - org.eclipse.jgit.internal.storage.file;version="[3.3.0,3.4.0)", - org.eclipse.jgit.internal.storage.pack;version="[3.3.0,3.4.0)", - org.eclipse.jgit.junit;version="[3.3.0,3.4.0)", - org.eclipse.jgit.lib;version="[3.3.0,3.4.0)", - org.eclipse.jgit.merge;version="[3.3.0,3.4.0)", - org.eclipse.jgit.nls;version="[3.3.0,3.4.0)", - org.eclipse.jgit.notes;version="[3.3.0,3.4.0)", - org.eclipse.jgit.patch;version="[3.3.0,3.4.0)", - org.eclipse.jgit.pgm;version="[3.3.0,3.4.0)", - org.eclipse.jgit.pgm.internal;version="[3.3.0,3.4.0)", - org.eclipse.jgit.revplot;version="[3.3.0,3.4.0)", - org.eclipse.jgit.revwalk;version="[3.3.0,3.4.0)", - org.eclipse.jgit.revwalk.filter;version="[3.3.0,3.4.0)", - org.eclipse.jgit.storage.file;version="[3.3.0,3.4.0)", - org.eclipse.jgit.storage.pack;version="[3.3.0,3.4.0)", - org.eclipse.jgit.submodule;version="[3.3.0,3.4.0)", - org.eclipse.jgit.transport;version="[3.3.0,3.4.0)", - org.eclipse.jgit.transport.http;version="[3.3.0,3.4.0)", - org.eclipse.jgit.treewalk;version="[3.3.0,3.4.0)", - org.eclipse.jgit.treewalk.filter;version="[3.3.0,3.4.0)", - org.eclipse.jgit.util;version="[3.3.0,3.4.0)", - org.eclipse.jgit.util.io;version="[3.3.0,3.4.0)", + org.eclipse.jgit.api;version="[3.3.1,3.4.0)", + org.eclipse.jgit.api.errors;version="[3.3.1,3.4.0)", + org.eclipse.jgit.awtui;version="[3.3.1,3.4.0)", + org.eclipse.jgit.blame;version="[3.3.1,3.4.0)", + org.eclipse.jgit.console;version="[3.3.1,3.4.0)", + org.eclipse.jgit.diff;version="[3.3.1,3.4.0)", + org.eclipse.jgit.dircache;version="[3.3.1,3.4.0)", + org.eclipse.jgit.errors;version="[3.3.1,3.4.0)", + org.eclipse.jgit.events;version="[3.3.1,3.4.0)", + org.eclipse.jgit.fnmatch;version="[3.3.1,3.4.0)", + org.eclipse.jgit.ignore;version="[3.3.1,3.4.0)", + org.eclipse.jgit.internal;version="[3.3.1,3.4.0)", + org.eclipse.jgit.internal.storage.dfs;version="[3.3.1,3.4.0)", + org.eclipse.jgit.internal.storage.file;version="[3.3.1,3.4.0)", + org.eclipse.jgit.internal.storage.pack;version="[3.3.1,3.4.0)", + org.eclipse.jgit.junit;version="[3.3.1,3.4.0)", + org.eclipse.jgit.lib;version="[3.3.1,3.4.0)", + org.eclipse.jgit.merge;version="[3.3.1,3.4.0)", + org.eclipse.jgit.nls;version="[3.3.1,3.4.0)", + org.eclipse.jgit.notes;version="[3.3.1,3.4.0)", + org.eclipse.jgit.patch;version="[3.3.1,3.4.0)", + org.eclipse.jgit.pgm;version="[3.3.1,3.4.0)", + org.eclipse.jgit.pgm.internal;version="[3.3.1,3.4.0)", + org.eclipse.jgit.revplot;version="[3.3.1,3.4.0)", + org.eclipse.jgit.revwalk;version="[3.3.1,3.4.0)", + org.eclipse.jgit.revwalk.filter;version="[3.3.1,3.4.0)", + org.eclipse.jgit.storage.file;version="[3.3.1,3.4.0)", + org.eclipse.jgit.storage.pack;version="[3.3.1,3.4.0)", + org.eclipse.jgit.submodule;version="[3.3.1,3.4.0)", + org.eclipse.jgit.transport;version="[3.3.1,3.4.0)", + org.eclipse.jgit.transport.http;version="[3.3.1,3.4.0)", + org.eclipse.jgit.treewalk;version="[3.3.1,3.4.0)", + org.eclipse.jgit.treewalk.filter;version="[3.3.1,3.4.0)", + org.eclipse.jgit.util;version="[3.3.1,3.4.0)", + org.eclipse.jgit.util.io;version="[3.3.1,3.4.0)", org.hamcrest;version="[1.1.0,2.0.0)", org.junit;version="[4.4.0,5.0.0)", org.junit.experimental.theories;version="[4.4.0,5.0.0)", diff --git a/org.eclipse.jgit.test/pom.xml b/org.eclipse.jgit.test/pom.xml index 55d546b257..29a87e9fd6 100644 --- a/org.eclipse.jgit.test/pom.xml +++ b/org.eclipse.jgit.test/pom.xml @@ -52,7 +52,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>3.3.0-SNAPSHOT</version> + <version>3.3.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.test</artifactId> diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/ResolveMergerTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/ResolveMergerTest.java index 54de8cfb47..dd06168c30 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/ResolveMergerTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/ResolveMergerTest.java @@ -53,6 +53,7 @@ import org.eclipse.jgit.api.Git; import org.eclipse.jgit.api.MergeResult; import org.eclipse.jgit.api.MergeResult.MergeStatus; import org.eclipse.jgit.api.errors.CheckoutConflictException; +import org.eclipse.jgit.api.errors.GitAPIException; import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.dircache.DirCache; import org.eclipse.jgit.errors.NoMergeBaseException; @@ -264,6 +265,37 @@ public class ResolveMergerTest extends RepositoryTestCase { indexState(CONTENT)); } + @Theory + public void mergeWithCrlfInWT(MergeStrategy strategy) throws IOException, + GitAPIException { + Git git = Git.wrap(db); + db.getConfig().setString("core", null, "autocrlf", "false"); + db.getConfig().save(); + writeTrashFile("crlf.txt", "some\r\ndata\r\n"); + git.add().addFilepattern("crlf.txt").call(); + git.commit().setMessage("base").call(); + + git.branchCreate().setName("brancha").call(); + + writeTrashFile("crlf.txt", "some\r\nmore\r\ndata\r\n"); + git.add().addFilepattern("crlf.txt").call(); + git.commit().setMessage("on master").call(); + + git.checkout().setName("brancha").call(); + writeTrashFile("crlf.txt", "some\r\ndata\r\ntoo\r\n"); + git.add().addFilepattern("crlf.txt").call(); + git.commit().setMessage("on brancha").call(); + + db.getConfig().setString("core", null, "autocrlf", "input"); + db.getConfig().save(); + + MergeResult mergeResult = git.merge().setStrategy(strategy) + .include(db.resolve("master")) + .call(); + assertEquals(MergeResult.MergeStatus.MERGED, + mergeResult.getMergeStatus()); + } + /** * Merging two equal subtrees when the index does not contain any file in * that subtree should lead to a merged state. |