- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Towards typesafe native Scala mocks
Sun, 2011-06-12, 00:49
Borachio, my native mocking library for Scala, works well enough but has a couple of annoying limitations:
- It can only mock functions and traits (interfaces). No support for classes, companion objects, constructors, etc. etc. etc.
- It’s not typesafe.
I've been working on a compiler plugin to address those limitations and, although I’m far from done, I’ve made enough progress to be worth reporting.
There's a writeup of on my blog:
http://www.paulbutcher.com/2011/06/towards-typesafe-native-scala-mocks/
I'd be very interested in feedback. If anyone who knows more about compiler internals and/or plugins than I do fancies casting an eye over the plugin and letting me know about anything that could be done better, I'd be very grateful indeed.
--
paul.butcher->msgCount++
Snetterton, Castle Combe, Cadwell Park...
Who says I have a one track mind?
http://www.paulbutcher.com/
LinkedIn: http://www.linkedin.com/in/paulbutcher
MSN: paul@paulbutcher.com
AIM: paulrabutcher
Skype: paulrabutcher