JBoss Community

JUnit test support for jBPM5

new comment by Maciej Swiderski View all comments on this document

Mauricio, Tihomir

 

first of all thanks for taking the time to look at it and for your comments. That was whole idea to post is as early draft to collect your thoughts since everybody has its own way of working with jBPM especially on the unit test phase.

Mauricio, I think both code bases can be merged to enhance the overall functionality of the test framework.

 

Tihomir, main idea behind using annotations rather than inheritance is that it is easer to get it when using custom JUnit runner (at least I find it easier). Of course I agree with you that it should be improved to reduce number of code lines required to write your tests (I admit I have not spent too much time on human tasks yet). But it has already some of these characteristics, for instance shared knowledge base so it will be built only once which in my eyes can be beneficial in quite some cases.

 

Regarding hiding setup code behind annotations - in my opinion writing a test case is more like you know what you are doing and you just want to make sure it is tested now and in the future. If you would like to get to know the framework you probably need to start with the getting started guide, api docs, etc rather than unit tests, that is my two cents ;)

 

By the way, if you have any ideas what would fit here I would be more than happy to include them.

 

P.S.

Currently I am away from my regular computer so cannot push it to the git repo, hopefully beginning of next week it will be available.

Cheers