Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Hohenegger2018-10-28 11:10:37 -0400
committerMichael Keppler2018-11-21 03:45:22 -0500
commitc0ec915e73313c04f6bdd9fd7030abddae00b587 (patch)
tree9420326889a6b95200b78fb02f712f61a2f884f0 /org.eclipse.egit.ui.test/src/org
parente50f98a4832f0af908b833453d03080be58c3743 (diff)
downloadegit-c0ec915e73313c04f6bdd9fd7030abddae00b587.tar.gz
egit-c0ec915e73313c04f6bdd9fd7030abddae00b587.tar.xz
egit-c0ec915e73313c04f6bdd9fd7030abddae00b587.zip
Refactoring: Moved refName validation method to core for better re-use
Also: - use IStatus result to avoid null and improve readability - use stream API for efficiency - use Message.format instead of NLS.bind Change-Id: I9118b18b6c0fce5ce1e381d8088061181b384eba Signed-off-by: Max Hohenegger <eclipse@hohenegger.eu>
Diffstat (limited to 'org.eclipse.egit.ui.test/src/org')
-rw-r--r--org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewBranchHandlingTest.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewBranchHandlingTest.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewBranchHandlingTest.java
index a267d25c7..7fb833101 100644
--- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewBranchHandlingTest.java
+++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewBranchHandlingTest.java
@@ -25,6 +25,7 @@ import java.util.concurrent.atomic.AtomicBoolean;
import org.eclipse.core.commands.State;
import org.eclipse.egit.core.RepositoryUtil;
+import org.eclipse.egit.core.internal.CoreText;
import org.eclipse.egit.core.op.BranchOperation;
import org.eclipse.egit.core.op.CloneOperation;
import org.eclipse.egit.ui.Activator;
@@ -322,7 +323,7 @@ public class GitRepositoriesViewBranchHandlingTest extends
newBranchNameText.setText("invalid~name");
renameDialog.bot().text(" " + // the text is now in the error message, and the MessageAreaDialog seems to add a space
- NLS.bind(UIText.ValidationUtils_InvalidRefNameMessage,
+ NLS.bind(CoreText.ValidationUtils_InvalidRefNameMessage,
"refs/heads/invalid~name"));
assertFalse(renameDialog.bot()
.button(UIText.RenameBranchDialog_RenameButtonLabel)

Back to the top