Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverabrahams committed Oct 2, 2024
1 parent e93271c commit e69880f
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions common/test/model/dotcomrendering/ElementEnhancerTest.scala
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ class ElementEnhancerTest extends AnyFlatSpec with Matchers {
"enhanceElement" should "add elementId and enhance ListBlockElement" in {
val mockElement: JsObject = Json.obj(
"_type" -> "model.dotcomrendering.pageElements.ListBlockElement",
"items" -> Json.arr(Json.obj(
"elements" -> Json.arr(Json.obj("_type" -> "model.dotcomrendering.pageElements.TextElement")))
)
"items" -> Json.arr(
Json.obj("elements" -> Json.arr(Json.obj("_type" -> "model.dotcomrendering.pageElements.TextElement"))),
),
)

val result = ElementsEnhancer.enhanceElement(mockElement)
Expand All @@ -31,10 +31,10 @@ class ElementEnhancerTest extends AnyFlatSpec with Matchers {
"sections" -> Json.arr(
Json.obj(
"events" -> Json.arr(
Json.obj("body" -> Json.arr(Json.obj("_type" -> "model.dotcomrendering.pageElements.TextElement")))
)
)
)
Json.obj("body" -> Json.arr(Json.obj("_type" -> "model.dotcomrendering.pageElements.TextElement"))),
),
),
),
)

val result = ElementsEnhancer.enhanceElement(mockElement)
Expand All @@ -51,7 +51,7 @@ class ElementEnhancerTest extends AnyFlatSpec with Matchers {
"enhanceElement" should "return the original element with elementId for unknown types" in {
val mockElement: JsObject = Json.obj(
"_type" -> "model.dotcomrendering.pageElements.TextElement",
"someField" -> "someValue"
"someField" -> "someValue",
)

val result = ElementsEnhancer.enhanceElement(mockElement)
Expand Down

0 comments on commit e69880f

Please sign in to comment.