diff options
Diffstat (limited to 'plugins/git4idea/tests')
10 files changed, 238 insertions, 134 deletions
diff --git a/plugins/git4idea/tests/git4idea/branch/GitBranchWorkerTest.groovy b/plugins/git4idea/tests/git4idea/branch/GitBranchWorkerTest.groovy index 35acc41fc3cc..9a2bad2ad663 100644 --- a/plugins/git4idea/tests/git4idea/branch/GitBranchWorkerTest.groovy +++ b/plugins/git4idea/tests/git4idea/branch/GitBranchWorkerTest.groovy @@ -14,16 +14,14 @@ * limitations under the License. */ package git4idea.branch -import com.intellij.dvcs.test.MockVirtualFile + import com.intellij.openapi.progress.ProgressIndicator import com.intellij.openapi.progress.util.ProgressIndicatorBase import com.intellij.openapi.project.Project import com.intellij.openapi.ui.DialogWrapper import com.intellij.openapi.util.io.FileUtil import com.intellij.openapi.util.text.StringUtil -import com.intellij.openapi.vcs.FilePathImpl import com.intellij.openapi.vcs.changes.Change -import com.intellij.openapi.vcs.changes.CurrentContentRevision import com.intellij.openapi.vfs.VirtualFile import com.intellij.util.Function import com.intellij.util.LineSeparator @@ -35,12 +33,11 @@ import git4idea.config.GitVersionSpecialty import git4idea.repo.GitRepository import git4idea.test.GitPlatformTest import org.jetbrains.annotations.NotNull +import org.jetbrains.annotations.Nullable import java.util.regex.Matcher -import static com.intellij.openapi.vcs.Executor.* -import static git4idea.test.GitExecutor.cd -import static git4idea.test.GitExecutor.git +import static git4idea.test.GitExecutor.* import static git4idea.test.GitScenarios.* class GitBranchWorkerTest extends GitPlatformTest { @@ -248,7 +245,7 @@ class GitBranchWorkerTest extends GitPlatformTest { List<Change> changes = null; checkoutOrMerge(operation, "feature", [ - showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, boolean force -> + showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, String force -> changes = cs DialogWrapper.CANCEL_EXIT_CODE } @@ -270,17 +267,6 @@ class GitBranchWorkerTest extends GitPlatformTest { return !GitVersionSpecialty.OLD_STYLE_OF_UNTRACKED_AND_LOCAL_CHANGES_WOULD_BE_OVERWRITTEN.existsIn(GitVersion.parse(git("version"))); } - Change[] changesFromFiles(Collection<String> paths) { - paths.collect { - toChange(it) - } - } - - Change toChange(String relPath) { - // we don't care about the before revision - new Change(null, CurrentContentRevision.create(new FilePathImpl(new MockVirtualFile(myProjectRoot + "/" + relPath)))) - } - public void "test agree to smart checkout should smart checkout"() { def localChanges = agree_to_smart_operation("checkout", "Checked out <b><code>feature</code></b>") @@ -345,7 +331,7 @@ class GitBranchWorkerTest extends GitPlatformTest { prepareLocalChangesOverwrittenBy(myUltimate) checkoutOrMerge(operation, "feature", [ - showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, boolean f + showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, String force -> GitSmartOperationDialog.CANCEL_EXIT_CODE }, ] as GitBranchUiHandler ) @@ -371,7 +357,7 @@ class GitBranchWorkerTest extends GitPlatformTest { def rollbackMsg = null checkoutOrMerge(operation, "feature", [ showSmartOperationDialog : { - Project p, List<Change> cs, Collection<String> paths, String op, boolean f -> GitSmartOperationDialog.CANCEL_EXIT_CODE + Project p, List<Change> cs, Collection<String> paths, String op, String f -> GitSmartOperationDialog.CANCEL_EXIT_CODE }, notifyErrorWithRollbackProposal: { String t, String m, String rp -> rollbackMsg = m; false } ] as GitBranchUiHandler ) @@ -384,7 +370,7 @@ class GitBranchWorkerTest extends GitPlatformTest { prepareLocalChangesOverwrittenBy(myUltimate) def uiHandler = [ - showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, boolean force -> + showSmartOperationDialog: { Project p, List<Change> cs, Collection<String> paths, String op, String force -> GitSmartOperationDialog.FORCE_EXIT_CODE; }, ] as GitBranchUiHandler @@ -611,6 +597,39 @@ class GitBranchWorkerTest extends GitPlatformTest { assertEquals "Merge in ultimate should have been reset", ultimateTipAfterMerge, tip(myUltimate) } + public void test_checkout_in_detached_head() { + cd(myCommunity); + touch("file.txt", "some content"); + add("file.txt"); + commit("msg"); + git(myCommunity, "checkout HEAD^"); + + checkoutBranch("master", []); + assertCurrentBranch("master"); + } + + // inspired by IDEA-127472 + public void test_checkout_to_common_branch_when_branches_have_diverged() { + branchWithCommit(myUltimate, "feature", "feature-file.txt", "feature_content", false); + branchWithCommit(myCommunity, "newbranch", "newbranch-file.txt", "newbranch_content", false); + checkoutBranch("master", []) + assertCurrentBranch("master"); + } + + public void test_rollback_checkout_from_diverged_branches_should_return_to_proper_branches() { + branchWithCommit(myUltimate, "feature", "feature-file.txt", "feature_content", false); + branchWithCommit(myCommunity, "newbranch", "newbranch-file.txt", "newbranch_content", false); + unmergedFiles(myContrib) + + checkoutBranch "master", [ + showUnmergedFilesMessageWithRollback: { String s1, String s2 -> true }, + ] + + assertCurrentBranch(myUltimate, "feature"); + assertCurrentBranch(myCommunity, "newbranch"); + assertCurrentBranch(myContrib, "master"); + } + static def assertCurrentBranch(GitRepository repository, String name) { def curBranch = git(repository, "branch").split("\n").find { it -> it.contains("*") }.replace('*', ' ').trim() assertEquals("Current branch is incorrect in ${repository}", name, curBranch) @@ -716,7 +735,7 @@ class GitBranchWorkerTest extends GitPlatformTest { @NotNull List<Change> changes, @NotNull Collection<String> paths, @NotNull String operation, - boolean isForcePossible) { + @Nullable String forceButton) { GitSmartOperationDialog.SMART_EXIT_CODE } diff --git a/plugins/git4idea/tests/git4idea/log/GitLogProviderTest.java b/plugins/git4idea/tests/git4idea/log/GitLogProviderTest.java index 797e0271b430..0bb67671622b 100644 --- a/plugins/git4idea/tests/git4idea/log/GitLogProviderTest.java +++ b/plugins/git4idea/tests/git4idea/log/GitLogProviderTest.java @@ -20,6 +20,7 @@ import com.intellij.openapi.util.Condition; import com.intellij.openapi.util.text.StringUtil; import com.intellij.openapi.vcs.VcsException; import com.intellij.util.ArrayUtil; +import com.intellij.util.CollectConsumer; import com.intellij.util.Consumer; import com.intellij.util.Function; import com.intellij.util.containers.ContainerUtil; @@ -84,9 +85,10 @@ public class GitLogProviderTest extends GitSingleRepoTest { prepareSomeHistory(); createTaggedBranch(); List<VcsCommitMetadata> expectedLog = log(); - @SuppressWarnings("unchecked") - List<TimedVcsCommit> actualLog = myLogProvider.readAllHashes(myProjectRoot, Consumer.EMPTY_CONSUMER); - assertOrderedEquals(expectedLog, actualLog); + List<TimedVcsCommit> collector = ContainerUtil.newArrayList(); + //noinspection unchecked + myLogProvider.readAllHashes(myProjectRoot, Consumer.EMPTY_CONSUMER, new CollectConsumer<TimedVcsCommit>(collector)); + assertOrderedEquals(expectedLog, collector); } public void test_get_current_user() throws Exception { diff --git a/plugins/git4idea/tests/git4idea/log/GitRefManagerTest.java b/plugins/git4idea/tests/git4idea/log/GitRefManagerTest.java index 707e97265267..14d88315c596 100644 --- a/plugins/git4idea/tests/git4idea/log/GitRefManagerTest.java +++ b/plugins/git4idea/tests/git4idea/log/GitRefManagerTest.java @@ -15,7 +15,7 @@ import git4idea.GitLocalBranch; import git4idea.GitRemoteBranch; import git4idea.branch.GitBranchesCollection; import git4idea.repo.*; -import git4idea.test.GitTestRepositoryManager; +import git4idea.test.GitMockRepositoryManager; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -145,7 +145,7 @@ public class GitRefManagerTest extends UsefulTestCase { } private static List<VcsRef> sort(final Collection<VcsRef> refs) { - final GitTestRepositoryManager manager = new GitTestRepositoryManager(); + final GitMockRepositoryManager manager = new GitMockRepositoryManager(); manager.add(new MockGitRepository() { @NotNull @Override @@ -304,5 +304,9 @@ public class GitRefManagerTest extends UsefulTestCase { public String toLogString() { throw new UnsupportedOperationException(); } + + @Override + public void dispose() { + } } } diff --git a/plugins/git4idea/tests/git4idea/test/GitExecutor.java b/plugins/git4idea/tests/git4idea/test/GitExecutor.java index 7c561c39ebc5..f1b042ae0565 100644 --- a/plugins/git4idea/tests/git4idea/test/GitExecutor.java +++ b/plugins/git4idea/tests/git4idea/test/GitExecutor.java @@ -53,11 +53,12 @@ public class GitExecutor extends Executor { printVersionTheFirstTime(); List<String> split = splitCommandInParameters(command); split.add(0, PathHolder.GIT_EXECUTABLE); - debug("# git " + command); + File workingDir = ourCurrentDir(); + debug("[" + workingDir.getName() + "] # git " + command); for (int attempt = 0; attempt < MAX_RETRIES; attempt++) { String stdout; try { - stdout = run(split, ignoreNonZeroExitCode); + stdout = run(workingDir, split, ignoreNonZeroExitCode); if (!isIndexLockFileError(stdout)) { return stdout; } @@ -97,7 +98,7 @@ public class GitExecutor extends Executor { } public static void add(@NotNull String path) { - git("add " + path); + git("add --verbose " + path); } public static void addCommit(@NotNull String message) { diff --git a/plugins/git4idea/tests/git4idea/test/GitHttpAuthTestService.java b/plugins/git4idea/tests/git4idea/test/GitHttpAuthTestService.java index b6f25e75e307..8723ce280269 100644 --- a/plugins/git4idea/tests/git4idea/test/GitHttpAuthTestService.java +++ b/plugins/git4idea/tests/git4idea/test/GitHttpAuthTestService.java @@ -15,13 +15,11 @@ */ package git4idea.test; -import com.intellij.openapi.application.ModalityState; import com.intellij.openapi.project.Project; import git4idea.commands.GitCommand; import git4idea.commands.GitHttpAuthService; import git4idea.commands.GitHttpAuthenticator; import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; /** * @author Kirill Likhodedov @@ -61,8 +59,7 @@ public class GitHttpAuthTestService extends GitHttpAuthService { @NotNull @Override - public GitHttpAuthenticator createAuthenticator(@NotNull Project project, @Nullable ModalityState state, @NotNull GitCommand command, - @NotNull String url) { + public GitHttpAuthenticator createAuthenticator(@NotNull Project project, @NotNull GitCommand command, @NotNull String url) { return myAuthenticator; } diff --git a/plugins/git4idea/tests/git4idea/test/GitMockRepositoryManager.java b/plugins/git4idea/tests/git4idea/test/GitMockRepositoryManager.java new file mode 100644 index 000000000000..21ed4da7bdfb --- /dev/null +++ b/plugins/git4idea/tests/git4idea/test/GitMockRepositoryManager.java @@ -0,0 +1,84 @@ +/* + * Copyright 2000-2013 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package git4idea.test; + +import com.intellij.dvcs.repo.RepositoryManager; +import com.intellij.openapi.vcs.FilePath; +import com.intellij.openapi.vfs.VirtualFile; +import git4idea.repo.GitRepository; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.ArrayList; +import java.util.List; + +/** + * @author Kirill Likhodedov + */ +public class GitMockRepositoryManager implements RepositoryManager<GitRepository> { + private final List<GitRepository> myRepositories = new ArrayList<GitRepository>(); + + public void add(GitRepository repository) { + myRepositories.add(repository); + } + + @Override + public GitRepository getRepositoryForRoot(@Nullable VirtualFile root) { + for (GitRepository repository : myRepositories) { + if (repository.getRoot().equals(root)) { + return repository; + } + } + + return null; + } + + @Override + public GitRepository getRepositoryForFile(@NotNull VirtualFile file) { + throw new UnsupportedOperationException(); + } + + @Override + public GitRepository getRepositoryForFile(@NotNull FilePath file) { + throw new UnsupportedOperationException(); + } + + @NotNull + @Override + public List<GitRepository> getRepositories() { + return myRepositories; + } + + @Override + public boolean moreThanOneRoot() { + return myRepositories.size() > 1; + } + + @Override + public void updateRepository(VirtualFile root) { + throw new UnsupportedOperationException(); + } + + @Override + public void updateAllRepositories() { + throw new UnsupportedOperationException(); + } + + @Override + public void waitUntilInitialized() { + } + +} diff --git a/plugins/git4idea/tests/git4idea/test/GitPlatformTest.java b/plugins/git4idea/tests/git4idea/test/GitPlatformTest.java index ef3f963c9c7e..c02ec553dd8f 100644 --- a/plugins/git4idea/tests/git4idea/test/GitPlatformTest.java +++ b/plugins/git4idea/tests/git4idea/test/GitPlatformTest.java @@ -19,6 +19,7 @@ import com.intellij.openapi.components.ProjectComponent; import com.intellij.openapi.components.ServiceManager; import com.intellij.openapi.diagnostic.Logger; import com.intellij.openapi.project.Project; +import com.intellij.openapi.util.text.StringUtil; import com.intellij.openapi.vcs.*; import com.intellij.openapi.vcs.changes.ChangeListManager; import com.intellij.openapi.vcs.changes.VcsDirtyScopeManager; @@ -51,19 +52,19 @@ public abstract class GitPlatformTest extends UsefulTestCase { private static final Logger LOG = Logger.getInstance(GitPlatformTest.class); - @NotNull protected Project myProject; - @NotNull protected VirtualFile myProjectRoot; - @NotNull protected String myProjectPath; - @NotNull protected GitRepositoryManager myGitRepositoryManager; - @NotNull protected GitVcsSettings myGitSettings; - @NotNull protected GitPlatformFacade myPlatformFacade; - @NotNull protected Git myGit; - @NotNull protected GitVcs myVcs; + protected Project myProject; + protected VirtualFile myProjectRoot; + protected String myProjectPath; + protected GitRepositoryManager myGitRepositoryManager; + protected GitVcsSettings myGitSettings; + protected GitPlatformFacade myPlatformFacade; + protected Git myGit; + protected GitVcs myVcs; - @NotNull protected TestDialogManager myDialogManager; - @NotNull protected TestVcsNotifier myVcsNotifier; + protected TestDialogManager myDialogManager; + protected TestVcsNotifier myVcsNotifier; - @NotNull private IdeaProjectTestFixture myProjectFixture; + private IdeaProjectTestFixture myProjectFixture; private String myTestStartedIndicator; @SuppressWarnings({"JUnitTestCaseWithNonTrivialConstructors", "UnusedDeclaration"}) @@ -86,35 +87,41 @@ public abstract class GitPlatformTest extends UsefulTestCase { throw e; } - myProject = myProjectFixture.getProject(); - myProjectRoot = myProject.getBaseDir(); - myProjectPath = myProjectRoot.getPath(); - - myGitSettings = GitVcsSettings.getInstance(myProject); - myGitSettings.getAppSettings().setPathToGit(GitExecutor.PathHolder.GIT_EXECUTABLE); - - myDialogManager = (TestDialogManager)ServiceManager.getService(DialogManager.class); - myVcsNotifier = (TestVcsNotifier)ServiceManager.getService(myProject, VcsNotifier.class); - - myGitRepositoryManager = GitUtil.getRepositoryManager(myProject); - myPlatformFacade = ServiceManager.getService(myProject, GitPlatformFacade.class); - myGit = ServiceManager.getService(myProject, Git.class); - myVcs = ObjectUtils.assertNotNull(GitVcs.getInstance(myProject)); - myVcs.doActivate(); - - GitTestUtil.assumeSupportedGitVersion(myVcs); - initChangeListManager(); - addSilently(); - removeSilently(); + try { + myProject = myProjectFixture.getProject(); + myProjectRoot = myProject.getBaseDir(); + myProjectPath = myProjectRoot.getPath(); + + myGitSettings = GitVcsSettings.getInstance(myProject); + myGitSettings.getAppSettings().setPathToGit(GitExecutor.PathHolder.GIT_EXECUTABLE); + + myDialogManager = (TestDialogManager)ServiceManager.getService(DialogManager.class); + myVcsNotifier = (TestVcsNotifier)ServiceManager.getService(myProject, VcsNotifier.class); + + myGitRepositoryManager = GitUtil.getRepositoryManager(myProject); + myPlatformFacade = ServiceManager.getService(myProject, GitPlatformFacade.class); + myGit = ServiceManager.getService(myProject, Git.class); + myVcs = ObjectUtils.assertNotNull(GitVcs.getInstance(myProject)); + myVcs.doActivate(); + + GitTestUtil.assumeSupportedGitVersion(myVcs); + initChangeListManager(); + addSilently(); + removeSilently(); + } + catch (Exception e) { + tearDown(); + throw e; + } } @Override @NotNull public String getTestName(boolean lowercaseFirstLetter) { String name = super.getTestName(lowercaseFirstLetter); - name = name.trim().replace(' ', '_'); - if (name.length() > 50) { - name = name.substring(0, 50); + name = StringUtil.shortenTextWithEllipsis(name.trim().replace(" ", "_"), 12, 6, "_"); + if (name.startsWith("_")) { + name = name.substring(1); } return name; } @@ -127,16 +134,25 @@ public abstract class GitPlatformTest extends UsefulTestCase { @Override protected void tearDown() throws Exception { try { - myDialogManager.cleanup(); - myVcsNotifier.cleanup(); - myProjectFixture.tearDown(); - - String tempTestIndicator = myTestStartedIndicator; - clearFields(this); - myTestStartedIndicator = tempTestIndicator; + if (myDialogManager != null) { + myDialogManager.cleanup(); + } + if (myVcsNotifier != null) { + myVcsNotifier.cleanup(); + } + if (myProjectFixture != null) { + myProjectFixture.tearDown(); + } } finally { - super.tearDown(); + try { + String tempTestIndicator = myTestStartedIndicator; + clearFields(this); + myTestStartedIndicator = tempTestIndicator; + } + finally { + super.tearDown(); + } } } diff --git a/plugins/git4idea/tests/git4idea/test/GitScenarios.groovy b/plugins/git4idea/tests/git4idea/test/GitScenarios.groovy index 77ecf0bc9e20..1fe574ad863d 100644 --- a/plugins/git4idea/tests/git4idea/test/GitScenarios.groovy +++ b/plugins/git4idea/tests/git4idea/test/GitScenarios.groovy @@ -38,14 +38,17 @@ class GitScenarios { /** * Create a branch with a commit and return back to master. */ - static def branchWithCommit(GitRepository repository, String name, String file = "branch_file.txt", String content = "branch content") { + static def branchWithCommit(GitRepository repository, String name, String file = "branch_file.txt", String content = "branch content", + boolean returnToMaster = true) { cd repository git("checkout -b $name") touch(file, content) git("add $file") git("commit -m branch_content") - git("checkout master") + if (returnToMaster) { + git("checkout master") + } } /** diff --git a/plugins/git4idea/tests/git4idea/test/GitTestRepositoryManager.java b/plugins/git4idea/tests/git4idea/test/GitTestRepositoryManager.java index 52bf562280fe..b02e952926c2 100644 --- a/plugins/git4idea/tests/git4idea/test/GitTestRepositoryManager.java +++ b/plugins/git4idea/tests/git4idea/test/GitTestRepositoryManager.java @@ -1,5 +1,5 @@ /* - * Copyright 2000-2013 JetBrains s.r.o. + * Copyright 2000-2014 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -15,70 +15,46 @@ */ package git4idea.test; -import com.intellij.dvcs.repo.RepositoryManager; -import com.intellij.openapi.vcs.FilePath; +import com.intellij.dvcs.repo.RepoStateException; +import com.intellij.openapi.project.Project; +import com.intellij.openapi.util.Disposer; +import com.intellij.openapi.vcs.ProjectLevelVcsManager; import com.intellij.openapi.vfs.VirtualFile; +import git4idea.GitPlatformFacade; import git4idea.repo.GitRepository; +import git4idea.repo.GitRepositoryImpl; +import git4idea.repo.GitRepositoryManager; import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; -import java.util.ArrayList; -import java.util.List; +public class GitTestRepositoryManager extends GitRepositoryManager { -/** - * @author Kirill Likhodedov - */ -public class GitTestRepositoryManager implements RepositoryManager<GitRepository> { - private final List<GitRepository> myRepositories = new ArrayList<GitRepository>(); + @NotNull private final Project myProject; + @NotNull private final GitPlatformFacade myFacade; - public void add(GitRepository repository) { - myRepositories.add(repository); - } - - @Override - public GitRepository getRepositoryForRoot(@Nullable VirtualFile root) { - for (GitRepository repository : myRepositories) { - if (repository.getRoot().equals(root)) { - return repository; - } - } - - return null; - } - - @Override - public GitRepository getRepositoryForFile(@NotNull VirtualFile file) { - throw new UnsupportedOperationException(); - } - - @Override - public GitRepository getRepositoryForFile(@NotNull FilePath file) { - throw new UnsupportedOperationException(); + public GitTestRepositoryManager(@NotNull Project project, + @NotNull GitPlatformFacade platformFacade, + @NotNull ProjectLevelVcsManager vcsManager) { + super(project, platformFacade, vcsManager); + myProject = project; + myFacade = platformFacade; } @NotNull @Override - public List<GitRepository> getRepositories() { - return myRepositories; - } - - @Override - public boolean moreThanOneRoot() { - return myRepositories.size() > 1; - } - - @Override - public void updateRepository(VirtualFile root) { - throw new UnsupportedOperationException(); - } - - @Override - public void updateAllRepositories() { - throw new UnsupportedOperationException(); - } - - @Override - public void waitUntilInitialized() { + protected GitRepository createRepository(@NotNull VirtualFile root) { + return new GitRepositoryImpl(root, myFacade, myProject, this, false) { + @Override + public void update() { + try { + super.update(); + } + catch (RepoStateException e) { + if (!Disposer.isDisposed(this)) { // project dir will simply be removed during dispose + throw e; + } + } + } + }; } } diff --git a/plugins/git4idea/tests/git4idea/test/GitTestUtil.java b/plugins/git4idea/tests/git4idea/test/GitTestUtil.java index 842b1b1a2bae..3525ad18f0fd 100644 --- a/plugins/git4idea/tests/git4idea/test/GitTestUtil.java +++ b/plugins/git4idea/tests/git4idea/test/GitTestUtil.java @@ -22,6 +22,7 @@ import com.intellij.openapi.vfs.LocalFileSystem; import com.intellij.openapi.vfs.VirtualFile; import git4idea.GitUtil; import git4idea.GitVcs; +import git4idea.config.GitVersion; import git4idea.repo.GitRepository; import org.jetbrains.annotations.NotNull; import org.jetbrains.ide.BuiltInServerManagerImpl; @@ -111,6 +112,7 @@ public class GitTestUtil { } public static void assumeSupportedGitVersion(@NotNull GitVcs vcs) { - assumeTrue(vcs.getVersion().isSupported()); + GitVersion version = vcs.getVersion(); + assumeTrue("Unsupported Git version: " + version, version.isSupported()); } } |