Skip navigation.

Amock ver9.6, Mock static method

Amock ver9.6, Mock static method

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 don’t 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.
* Don’t need extending specific class.