aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.test
diff options
context:
space:
mode:
authorDavid Pursehouse <david.pursehouse@gmail.com>2019-01-20 15:12:45 +0900
committerDavid Pursehouse <david.pursehouse@gmail.com>2019-01-20 15:12:45 +0900
commit1a2db96c79f3e6fdf402ffa9f85f8e48303ac8ff (patch)
tree3c9421c5391e652492d41378fdd6b5e417828c17 /org.eclipse.jgit.test
parent283830a6437ae05f06f65da2f96321beb6196318 (diff)
downloadjgit-1a2db96c79f3e6fdf402ffa9f85f8e48303ac8ff.tar.gz
jgit-1a2db96c79f3e6fdf402ffa9f85f8e48303ac8ff.zip
Stop using deprecated methods of RemoteSetUrlCommand/RemoteRemoveCommand
Change-Id: I5234474b359a32bdae501b181f0726be2af1ec6a Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Diffstat (limited to 'org.eclipse.jgit.test')
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteDeleteCommandTest.java2
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteSetUrlCommandTest.java11
2 files changed, 7 insertions, 6 deletions
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteDeleteCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteDeleteCommandTest.java
index 7055daff9a..50e7095792 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteDeleteCommandTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteDeleteCommandTest.java
@@ -56,7 +56,7 @@ public class RemoteDeleteCommandTest extends AbstractRemoteCommandTest {
// execute the command to remove the remote
RemoteRemoveCommand cmd = Git.wrap(db).remoteRemove();
- cmd.setName(REMOTE_NAME);
+ cmd.setRemoteName(REMOTE_NAME);
RemoteConfig remote = cmd.call();
// assert that the removed remote is the initial remote
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteSetUrlCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteSetUrlCommandTest.java
index 6969c3df6c..d3265fee70 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteSetUrlCommandTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RemoteSetUrlCommandTest.java
@@ -45,6 +45,7 @@ package org.eclipse.jgit.api;
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertEquals;
+import org.eclipse.jgit.api.RemoteSetUrlCommand.UriType;
import org.eclipse.jgit.transport.RemoteConfig;
import org.eclipse.jgit.transport.URIish;
import org.junit.Test;
@@ -58,9 +59,9 @@ public class RemoteSetUrlCommandTest extends AbstractRemoteCommandTest {
// execute the command to change the fetch url
RemoteSetUrlCommand cmd = Git.wrap(db).remoteSetUrl();
- cmd.setName(REMOTE_NAME);
+ cmd.setRemoteName(REMOTE_NAME);
URIish newUri = new URIish("git://test.com/test");
- cmd.setUri(newUri);
+ cmd.setRemoteUri(newUri);
RemoteConfig remote = cmd.call();
// assert that the changed remote has the new fetch url
@@ -79,10 +80,10 @@ public class RemoteSetUrlCommandTest extends AbstractRemoteCommandTest {
// execute the command to change the push url
RemoteSetUrlCommand cmd = Git.wrap(db).remoteSetUrl();
- cmd.setName(REMOTE_NAME);
+ cmd.setRemoteName(REMOTE_NAME);
URIish newUri = new URIish("git://test.com/test");
- cmd.setUri(newUri);
- cmd.setPush(true);
+ cmd.setRemoteUri(newUri);
+ cmd.setUriType(UriType.PUSH);
RemoteConfig remote = cmd.call();
// assert that the changed remote has the old fetch url and the new push