Skip to content

Commit

Permalink
Fix GetSynonymsSetResponse (#3097)
Browse files Browse the repository at this point in the history
  • Loading branch information
Philippus committed Jun 26, 2024
1 parent ecc8cc8 commit e04ce88
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
package com.sksamuel.elastic4s.requests.synonyms

case class GetSynonymsSetResponse(count: Int, synonymsSet: Seq[SynonymRule])
import com.fasterxml.jackson.annotation.JsonProperty

case class GetSynonymsSetResponse(count: Int, @JsonProperty("synonyms_set") synonymsSet: Seq[SynonymRule])
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ class SynonymsTest extends AnyFlatSpec with Matchers with ElasticDsl with Docker
val resp = client.execute {
getSynonymsSet("my-synonyms-set")
}.await.result

resp.count shouldBe 3
resp.synonymsSet.map(_.synonyms).toSet shouldBe Set("hello, hi", "bye, goodbye", "test => check")
}

it should "handle errors" in {
Expand Down

0 comments on commit e04ce88

Please sign in to comment.