diff --git a/pom.xml b/pom.xml
index d3c16b7..275f36f 100644
--- a/pom.xml
+++ b/pom.xml
@@ -96,13 +96,6 @@
-
-
- com.squareup.okhttp
- okhttp-urlconnection
- 2.7.5
-
-
diff --git a/src/test/java/jenkins/plugins/github/api/SmokeTest.java b/src/test/java/jenkins/plugins/github/api/SmokeTest.java
index 06496d9..866fc3f 100644
--- a/src/test/java/jenkins/plugins/github/api/SmokeTest.java
+++ b/src/test/java/jenkins/plugins/github/api/SmokeTest.java
@@ -5,11 +5,10 @@
import java.util.Set;
import java.util.TreeSet;
-import com.squareup.okhttp.OkHttpClient;
-import com.squareup.okhttp.OkUrlFactory;
import jenkins.plugins.github.api.mock.MockGitHub;
import jenkins.plugins.github.api.mock.MockOrganization;
import jenkins.plugins.github.api.mock.MockUser;
+import okhttp3.OkHttpClient;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
@@ -18,8 +17,7 @@
import org.kohsuke.github.GHUser;
import org.kohsuke.github.GitHub;
import org.kohsuke.github.GitHubBuilder;
-import org.kohsuke.github.HttpConnector;
-import org.kohsuke.github.extras.OkHttpConnector;
+import org.kohsuke.github.connector.GitHubConnector;
import org.kohsuke.github.extras.okhttp3.OkHttpGitHubConnector;
import edu.umd.cs.findbugs.annotations.NonNull;
@@ -52,13 +50,10 @@ public SmokeTest(IOFunction connectFunction) {
@Parameterized.Parameters(name = "connectFunction={index}")
public static IOFunction[] connectFunctions() {
- HttpConnector okHttpConnector = new OkHttpConnector(new OkUrlFactory(new OkHttpClient()));
- HttpConnector okHttp3Connector = new org.kohsuke.github.extras.okhttp3.OkHttpConnector(new okhttp3.OkHttpClient());
- OkHttpGitHubConnector okHttpGitHubConnector = new OkHttpGitHubConnector(new okhttp3.OkHttpClient());
+ OkHttpClient okHttpClient = new OkHttpClient();
+ GitHubConnector okHttpGitHubConnector = new OkHttpGitHubConnector(okHttpClient);
ArrayList list = new ArrayList<>();
list.add ((mock) -> GitHub.connectToEnterpriseAnonymously(mock.open()));
- list.add ((mock) -> new GitHubBuilder().withConnector(okHttpConnector).withEndpoint(mock.open()).build());
- list.add ((mock) -> new GitHubBuilder().withConnector(okHttp3Connector).withEndpoint(mock.open()).build());
list.add ((mock) -> new GitHubBuilder().withConnector(okHttpGitHubConnector).withEndpoint(mock.open()).build());
return list.toArray(new IOFunction[] {});