Checker

doobie.scalatest.Checker
trait Checker[M[_]] extends CheckerBase[M]

Mix-in trait for specifications that enables checking of doobie Query and Update values. Users must provide an effect type M as well as a Transactor[M] and instances. As a convenience doobie provides specializations for common effect types (see other types in this package).

// An example specification, taken from the examples project.
class ExampleSpec extends AnyFunSuite with IOChecker {

 // The transactor to use for the tests.
 val transactor = Transactor.fromDriverManager[IO](...)

 // Now just mention the queries. Arguments are not used.
 test("findByNameAndAge") { check(MyDaoModule.findByNameAndAge(null, 0)) }
 test("allWoozles") { check(MyDaoModule.allWoozles) }

}

Attributes

Source:
Checker.scala
Graph
Supertypes
trait CheckerBase[M]
class Object
trait Matchable
class Any
Known subtypes
trait IOChecker
Self type
Assertions

Members list

Concise view

Value members

Concrete methods

def check[A](a: A)(using evidence$1: Analyzable[A]): Unit

Attributes

Source:
Checker.scala
def checkOutput[A](q: Query0[A])(using evidence$2: TypeName[A]): Unit

Attributes

Source:
Checker.scala
def checkOutput[A, B](q: Query[A, B])(using evidence$3: TypeName[A], evidence$4: TypeName[B]): Unit

Attributes

Source:
Checker.scala
def checkOutput[A](u: Update[A])(using evidence$5: TypeName[A]): Unit

Attributes

Source:
Checker.scala
def checkOutput(u: Update0): Unit

Attributes

Source:
Checker.scala

Inherited methods

def colors: Colors

Attributes

Inherited from:
CheckerBase
Source:
analysis.scala
def transactor: Transactor[M]

Attributes

Inherited from:
CheckerBase
Source:
analysis.scala

Implicits

Inherited implicits

implicit def M: Sync[M]

Attributes

Inherited from:
CheckerBase
Source:
analysis.scala
implicit def U: UnsafeRun[M]

Attributes

Inherited from:
CheckerBase
Source:
analysis.scala