diff options
author | Ivan Topolnjak <ivantopo@gmail.com> | 2016-04-01 13:20:20 +0200 |
---|---|---|
committer | Ivan Topolnjak <ivantopo@gmail.com> | 2016-04-01 13:20:20 +0200 |
commit | 63321f6467f173dc8ca16ed9e7b048b484d681e9 (patch) | |
tree | 6b7a8a8e8476af0dc88228e21f343f1374a33df8 /kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala | |
parent | d5ed007f3ac76fd1e1146d00a6665a4690af5c83 (diff) | |
download | Kamon-63321f6467f173dc8ca16ed9e7b048b484d681e9.tar.gz Kamon-63321f6467f173dc8ca16ed9e7b048b484d681e9.tar.bz2 Kamon-63321f6467f173dc8ca16ed9e7b048b484d681e9.zip |
core: catch any exception being thrown when recording values on histograms
fixes #232, fixes #332
Diffstat (limited to 'kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala')
-rw-r--r-- | kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala b/kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala index adfcd826..dd60fee1 100644 --- a/kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala +++ b/kamon-core/src/test/scala/kamon/metric/instrument/HistogramSpec.scala @@ -32,10 +32,8 @@ class HistogramSpec extends WordSpec with Matchers { histogram.record(10000) } - "fail when recording values higher than the highest trackable value" in new HistogramFixture { - intercept[IndexOutOfBoundsException] { - histogram.record(1000000) - } + "not fail when recording values higher than the highest trackable value" in new HistogramFixture { + histogram.record(Long.MaxValue) } "reset all recorded levels to zero after a snapshot collection" in new HistogramFixture { |