summaryrefslogtreecommitdiffstats
path: root/application
diff options
context:
space:
mode:
authorBjørn Christian Seime <bjorncs@yahoo-inc.com>2017-07-12 14:47:34 +0200
committerBjørn Christian Seime <bjorncs@yahoo-inc.com>2017-07-13 14:35:28 +0200
commit477d1b80e1e0468732470a46b82b2f08542f21d2 (patch)
treecfda3279472f0d8eface617fa5caec1513b53b52 /application
parent87afc48aa6742cf65571cbea860e6a04e2df45a5 (diff)
Treat Scala warnings as errors. Remove use of deprecated Scala APIs
Diffstat (limited to 'application')
-rw-r--r--application/src/test/scala/com/yahoo/application/container/jersey/JerseyTest.scala16
1 files changed, 6 insertions, 10 deletions
diff --git a/application/src/test/scala/com/yahoo/application/container/jersey/JerseyTest.scala b/application/src/test/scala/com/yahoo/application/container/jersey/JerseyTest.scala
index 5801197602b..cdf2d9ee1c6 100644
--- a/application/src/test/scala/com/yahoo/application/container/jersey/JerseyTest.scala
+++ b/application/src/test/scala/com/yahoo/application/container/jersey/JerseyTest.scala
@@ -1,27 +1,23 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.application.container.jersey
-import java.nio.file.{Path, Files, Paths}
+import java.nio.file.{Files, Path, Paths}
import javax.ws.rs.core.UriBuilder
import com.yahoo.application.Networking
-
+import com.yahoo.application.container.JDiscTest._
import com.yahoo.container.test.jars.jersey.resources.TestResourceBase
+import com.yahoo.container.test.jars.jersey.{resources => jarResources}
import com.yahoo.vespa.scalalib.osgi.maven.ProjectBundleClassPaths
import com.yahoo.vespa.scalalib.osgi.maven.ProjectBundleClassPaths.BundleClasspathMapping
import org.apache.http.HttpResponse
import org.apache.http.client.methods.HttpGet
-import org.apache.http.impl.client.DefaultHttpClient
+import org.apache.http.impl.client.HttpClientBuilder
import org.apache.http.util.EntityUtils
+import org.hamcrest.CoreMatchers.is
import org.junit.Assert._
import org.junit.Test
-import com.yahoo.container.test.jars.jersey.{resources => jarResources}
-
-import org.hamcrest.CoreMatchers.is
-
-import com.yahoo.application.container.JDiscTest._
-
import scala.io.Source
/**
@@ -125,7 +121,7 @@ class JerseyTest {
</services>,
Networking.enable)) { jdisc =>
- val client = new DefaultHttpClient
+ val client = HttpClientBuilder.create().build()
def httpGetter(path: HttpPath) = {
client.execute(new HttpGet(s"http://localhost:$getListenPort/rest-api/${path.stripPrefix("/")}"))