diff options
author | Dave Borowitz <dborowitz@google.com> | 2012-06-25 10:46:36 -0700 |
---|---|---|
committer | Kevin Sawicki <kevin@github.com> | 2012-06-25 10:46:36 -0700 |
commit | 2444aa231a3a9618a413b7e42e8120b42258702d (patch) | |
tree | 20eeef09e87d9940c3ab9812408dada1d10b0d56 /org.eclipse.jgit.test/tst | |
parent | 1bf5b9c7a8d2d6c254cdb022100e9172bae6cf56 (diff) | |
download | jgit-2444aa231a3a9618a413b7e42e8120b42258702d.tar.gz jgit-2444aa231a3a9618a413b7e42e8120b42258702d.zip |
Use the working tree's .gitmodules in SubmoduleWalk.forIndex()
This was broken in fe1f1b8f8aba60fdd1ad6f0f72e9c9180978cc60, which
preferred the index over the working tree when both were present.
Change-Id: I97dcf9a088adcbd0187fa7eec9ef34445ce3a981
Signed-off-by: Kevin Sawicki <kevin@github.com>
Diffstat (limited to 'org.eclipse.jgit.test/tst')
-rw-r--r-- | org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java index 0669dd1993..cb3c7d88f0 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java @@ -299,13 +299,13 @@ public class SubmoduleWalkTest extends RepositoryTestCase { final Config gitmodules = new Config(); gitmodules.setString(CONFIG_SUBMODULE_SECTION, path, CONFIG_KEY_PATH, "sub"); + // Different config in the index should be overridden by the working tree. gitmodules.setString(CONFIG_SUBMODULE_SECTION, path, CONFIG_KEY_URL, - "git://example.com/sub"); + "git://example.com/bad"); final RevBlob gitmodulesBlob = testDb.blob(gitmodules.toText()); - // Different config in the working tree. gitmodules.setString(CONFIG_SUBMODULE_SECTION, path, CONFIG_KEY_URL, - "git://example.com/bad"); + "git://example.com/sub"); writeTrashFile(DOT_GIT_MODULES, gitmodules.toText()); DirCache cache = db.lockDirCache(); |