Skip to content

Instantly share code, notes, and snippets.

@anatolyra
Created May 11, 2017 10:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anatolyra/38a6c3de8f78fb0cb1d2a2275e2ff42a to your computer and use it in GitHub Desktop.
Save anatolyra/38a6c3de8f78fb0cb1d2a2275e2ff42a to your computer and use it in GitHub Desktop.
import scalikejdbc.{DBSession, NamedDB}
package object testdata {
private[testdata] implicit class NamedDbSession(namedDB: NamedDB) {
def withSession[A](session: DBSession)(execution: DBSession => A): A =
execution(session)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment