Skip to content

Instantly share code, notes, and snippets.

@wsargent
Created October 30, 2010 20:47
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 wsargent/655724 to your computer and use it in GitHub Desktop.
Save wsargent/655724 to your computer and use it in GitHub Desktop.
Want to do a callback
def setupMocks(onSubmitFunc(): => acm:ApplicationContextMock): Unit = {
val acm: ApplicationContextMock = new ApplicationContextMock
onSubmitFunc(acm)
tester = new WicketTester(new Application {
protected override def getSpringInjector: SpringComponentInjector = {
return new SpringComponentInjector(this, acm, true)
}
})
}
setupMocks({
val eventDao: EventDao = Mockito.mock(classOf[EventDao])
acm.putBean("eventDao", EventDao)
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment