ofc. there is a framework for that, please have a look here and the builtin unit tests, e.g. here or here, hope you get the pattern: some_module/misc/java/test