Skip to content

Instantly share code, notes, and snippets.

@anatolyra anatolyra/ContextAfter.scala Secret
Created May 11, 2017

Embed
What would you like to do?
trait Context extends Scope with After {
val person = Person(carId = None).save() // creating data for test
val car = Car(color = "green", ownerId = None).save()
override def after: Any = {
// Clean db after test.
person.destroy()
car.destroy()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.