This post originated from an RSS feed registered with Java Buzz
by News Manager.
Original Post: Amock ver9.6, Mock static method
Feed Title: testdriven.com
Feed URL: http://feeds.feedburner.com/testdrivennewslinks?news=10&links=10
Feed Description: Your test-driven development community
Amock is AspecJ based mock library. It will give you java mock which you have dreamed.
With Amock, you * Can mock static method and constructor. -> You can unit test with singleton. * Can create mock object of a class which have only private constructor. * Can create mock instance of interface and normal class instance. * Can create mock object without any parameter even if the class does not have default constructor. -> You dont need to create expensive object just for mock constructor. * Can access private method and attribute easily. * Can mock private and protected method. * Can use argument checker (argument matcher 'eq(). any()...') only where it is needed. * Dont need extending specific class.