From 433bd42c21c04a8c9af2400eadabd82e6a524c12 Mon Sep 17 00:00:00 2001 From: Diego Date: Sun, 30 Nov 2014 17:24:37 -0300 Subject: + play, spray, newrelic: store in TraceLocal useful data to diagnose errors and closes #6 --- .../src/test/scala/kamon/spray/SprayServerTracingSpec.scala | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'kamon-spray/src/test/scala') diff --git a/kamon-spray/src/test/scala/kamon/spray/SprayServerTracingSpec.scala b/kamon-spray/src/test/scala/kamon/spray/SprayServerTracingSpec.scala index 48253b1d..30d42eea 100644 --- a/kamon-spray/src/test/scala/kamon/spray/SprayServerTracingSpec.scala +++ b/kamon-spray/src/test/scala/kamon/spray/SprayServerTracingSpec.scala @@ -24,11 +24,7 @@ import kamon.Kamon import org.scalatest.concurrent.{ PatienceConfiguration, ScalaFutures } import spray.http.HttpHeaders.RawHeader import spray.http.{ HttpResponse, HttpRequest } -import kamon.metric.{ TraceMetrics, Metrics } -import kamon.metric.Subscriptions.TickMetricSnapshot import com.typesafe.config.ConfigFactory -import kamon.metric.TraceMetrics.ElapsedTime -import kamon.metric.instrument.Histogram class SprayServerTracingSpec extends TestKitBase with WordSpecLike with Matchers with RequestBuilding with ScalaFutures with PatienceConfiguration with TestServer { @@ -81,7 +77,7 @@ class SprayServerTracingSpec extends TestKitBase with WordSpecLike with Matchers server.reply(HttpResponse(entity = "ok")) val response = client.expectMsgType[HttpResponse] - response.headers.filter(_.name == Kamon(Spray).traceTokenHeaderName).size should be(1) + response.headers.count(_.name == Kamon(Spray).traceTokenHeaderName) should be(1) } @@ -96,7 +92,7 @@ class SprayServerTracingSpec extends TestKitBase with WordSpecLike with Matchers server.reply(HttpResponse(entity = "ok")) val response = client.expectMsgType[HttpResponse] - response.headers should not contain (RawHeader(Kamon(Spray).traceTokenHeaderName, "propagation-disabled")) + response.headers should not contain RawHeader(Kamon(Spray).traceTokenHeaderName, "propagation-disabled") } } -- cgit v1.2.3