- GAEUnit was nice, but slow. Even when running tests in parallel I still had to go through the process of opening the browser, navigating to the right place and letting the tests run. Compare this to ctrl-f9 and seeing the following:
In the end it was relatively simple once I started employing mocking to deal with sessions and realized that I could actually issue real request objects to my handlers with relative ease...
webObReq = Request.blank(url)
webApReq = webapp.Request(webObReq.environ)
handler.initialize(webApReq, webapp.Response())
For the mocking I eventually decided to go with this framework:
It has so far been fine for my needs and at least my handlers have almost achieved 100% coverage. The syntax is a little foreign compared to Moq, but hasn't been a blocker to me actually getting work done so I'd recommend it.


Hey - I shared a similar frustration with gaeunit testing until I managed to integrate it with junit formatted output and then put the source tree in a CI engine (hudson). Now, I don't ever both running a whole suite of tests - just the ones relevant to the code at hand and when I checkin ... Boom, test reports etc etc all auto generated for me. Oh and happy sun icons too !
ReplyDelete