Commit aebd0b06 authored by Georg Mittendorfer's avatar Georg Mittendorfer

Add test.

parent 1a14bf9f
......@@ -85,6 +85,15 @@ public class MeterFactoryTest {
assertThat(fooCounter.getId().getTag("command")).isEqualTo("fooCommand");
}
@Test
public void shouldCreateFailedCommandCounter() {
Counter fooCounter = factory.createFailedCommandCounter("foo-command", "foo-error");
assertThat(fooCounter).isNotNull();
assertThat(fooCounter.getId().getName()).isEqualTo("iri.commands.retry");
assertThat(fooCounter.getId().getTag("command")).isEqualTo("foo-command");
assertThat(fooCounter.getId().getTag("error")).isEqualTo("foo-error");
}
@Test
public void givenDifferentCommandsWhenCreateThenReturnDifferentCounter() {
Counter fooCounter = factory.createRejectedCommandCounter("fooCommand");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment