Skip to content

Commit

Permalink
#118: fixing IT tests, caused by recent auto-rename/refactoring error
Browse files Browse the repository at this point in the history
  • Loading branch information
lsulak committed Apr 3, 2024
1 parent c674be9 commit fef374d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ class DoobieMultipleResultFunctionWithStatusTest extends AnyFunSuite with Doobie
values => Seq(fr"${values.lastName}", fr"${values.firstName}")
}

class GetActorsByLastnameStatusAggregator(implicit schema: DBSchema, dbEngine: DoobieEngine[IO])
class GetActorsByLastname(implicit schema: DBSchema, dbEngine: DoobieEngine[IO])
// Option[Actor] because: Actor might not exist, and the function would return only status info without actor data
extends DoobieMultipleResultFunctionWithStatus[GetActorsByLastnameQueryParameters, Option[Actor], IO](getActorsByLastnameQueryFragments)
with StandardStatusHandling
with ByMajorityErrorsStatusAggregator {
override def fieldsToSelect: Seq[String] = super.fieldsToSelect ++ Seq("actor_id", "first_name", "last_name")
}

private val getActorsByLastname = new GetActorsByLastnameStatusAggregator()(Integration, new DoobieEngine(transactor))
private val getActorsByLastname = new GetActorsByLastname()(Integration, new DoobieEngine(transactor))

test("Retrieving multiple actors from database, lastName match") {
val expectedResultElem = Set(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import scala.concurrent.ExecutionContext.Implicits.global

class SlickMultipleResultFunctionWithStatusTest extends AnyFunSuite with SlickTest with ScalaFutures {

class GetActorsByLastnameStatusAggregator(implicit override val schema: DBSchema, val dbEngine: SlickPgEngine)
class GetActorsByLastname(implicit override val schema: DBSchema, val dbEngine: SlickPgEngine)
extends SlickMultipleResultFunctionWithStatus[GetActorsByLastnameQueryParameters, Option[Actor]]
with StandardStatusHandling
with ByFirstErrorStatusAggregator
Expand All @@ -44,7 +44,7 @@ class SlickMultipleResultFunctionWithStatusTest extends AnyFunSuite with SlickTe
}
}

private val getActorsByLastname = new GetActorsByLastnameStatusAggregator()(Integration, new SlickPgEngine(db))
private val getActorsByLastname = new GetActorsByLastname()(Integration, new SlickPgEngine(db))

test("Retrieving actors from database") {
val expectedResultElem = Set(
Expand Down

0 comments on commit fef374d

Please sign in to comment.