diff --git a/README.md b/README.md index 80113d5..47f7f90 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ repositories { } } -compile('no.fint:fint-event-model:0.0.14') +compile('no.fint:fint-event-model:0.0.15') ``` ## Usage diff --git a/build.gradle b/build.gradle index beeb372..fe880ec 100644 --- a/build.gradle +++ b/build.gradle @@ -12,7 +12,7 @@ sourceCompatibility = 1.8 jar { baseName = 'fint-event-model' - version = '0.0.15-SNAPSHOT' + version = '0.0.15' } repositories { diff --git a/src/main/java/no/fint/event/model/DefaultActions.java b/src/main/java/no/fint/event/model/DefaultActions.java index a6c216c..c7b3051 100644 --- a/src/main/java/no/fint/event/model/DefaultActions.java +++ b/src/main/java/no/fint/event/model/DefaultActions.java @@ -1,7 +1,5 @@ package no.fint.event.model; public enum DefaultActions { - ; - - public static final String HEALTH = "health"; + HEALTH } diff --git a/src/main/java/no/fint/event/model/Event.java b/src/main/java/no/fint/event/model/Event.java index 2d6497c..e9fe498 100644 --- a/src/main/java/no/fint/event/model/Event.java +++ b/src/main/java/no/fint/event/model/Event.java @@ -249,7 +249,7 @@ public void addData(T data) { */ @JsonIgnore public boolean isHealthCheck() { - return DefaultActions.HEALTH.equals(action); + return DefaultActions.HEALTH.name().equals(action); } /** diff --git a/src/test/groovy/no/fint/event/model/EventSpec.groovy b/src/test/groovy/no/fint/event/model/EventSpec.groovy index b32e0bc..c813220 100644 --- a/src/test/groovy/no/fint/event/model/EventSpec.groovy +++ b/src/test/groovy/no/fint/event/model/EventSpec.groovy @@ -55,7 +55,7 @@ class EventSpec extends Specification { def "Check if event is health check when action is HEALTH"() { when: - def event = new Event(action: DefaultActions.HEALTH) + def event = new Event(action: 'HEALTH') then: event.isHealthCheck()