aboutsummaryrefslogtreecommitdiff
path: root/src/test/scala/kamon/instrumentation/ActorSystemInstrumentationSpec.scala
blob: 489f3c1c94dbf762fcd3b73da09d2fc576871453 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
package kamon.instrumentation

import org.scalatest.{Matchers, WordSpec}
import akka.actor.ActorSystem
import kamon.Kamon

class ActorSystemInstrumentationSpec extends WordSpec with Matchers {

  // TODO: Selection filters to exclude unwanted actor systems. Read from configuration.

  "the actor system instrumentation" should {
    "register all actor systems created" in {
      val as1 = ActorSystem("as1")
      val as2 = ActorSystem("as2")


      Kamon.Metric.actorSystem("as1") should not be (None)
      Kamon.Metric.actorSystem("as2") should not be (None)
      /*assert(Kamon.Metric.actorSystem("as2") != null)
      assert(Kamon.Metric.actorSystem("as3") === null)*/
    }
  }
}