From beba12d191eb19506e64a59750f4014cd377ee29 Mon Sep 17 00:00:00 2001 From: David Lebl Date: Wed, 29 Jan 2025 19:43:25 +0000 Subject: [PATCH] Add test for issue #2144 with fixed formating --- .../src/test/scala/doobie/util/ReadSuite.scala | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/modules/core/src/test/scala/doobie/util/ReadSuite.scala b/modules/core/src/test/scala/doobie/util/ReadSuite.scala index b0bee32b1..26e6b78ce 100644 --- a/modules/core/src/test/scala/doobie/util/ReadSuite.scala +++ b/modules/core/src/test/scala/doobie/util/ReadSuite.scala @@ -183,16 +183,20 @@ class ReadSuite extends munit.FunSuite with ReadSuitePlatform { _ <- sql"insert into foo values (1, 'a'), (2, 'b'), (3, 'c')".update.run _ <- sql"insert into bar values (1, 1, 'c'), (2, 2, null)".update.run - q <- sql"select f.foo_key, f.foo_value, b.bar_key, b.bar_value from foo f left join bar b on f.foo_key = b.foo_key".query[(Foo, Option[Bar])].to[List] + q <- + sql"select f.foo_key, f.foo_value, b.bar_key, b.bar_value from foo f left join bar b on f.foo_key = b.foo_key" + .query[(Foo, Option[Bar])].to[List] } yield q) .transact(xa) .unsafeRunSync() - assertEquals(result, List( - (Foo(1, "a"), Some(Bar(1, Some("c")))), - (Foo(2, "b"), Some(Bar(2, None))), - (Foo(3, "c"), None) - )) + assertEquals( + result, + List( + (Foo(1, "a"), Some(Bar(1, Some("c")))), + (Foo(2, "b"), Some(Bar(2, None))), + (Foo(3, "c"), None) + )) } test("Read should read correct columns for instances with Option (Some)") {