DUnit - class MyTest { mixin TestMixin; void testMethod1() {} void testMethod2() {}}

Rio rio at orum.dlang.org
Wed Mar 21 13:04:38 PDT 2012


On Wednesday, 21 March 2012 at 17:29:59 UTC, Juan Manuel Cabo
wrote:
> Btw, here is the whole list:
>     
> http://www.junit.org/junit/javadoc/3.8.1/junit/framework/Assert.html
>
>
> Do you have any thoughts?

Be careful: for JUnit 4 there is a separation of concerns.

The assertions are now the responsibility of the Hamcrest
library: http://code.google.com/p/hamcrest/
(Wouldn't it be nice to have a port to D?)

On the other hand, D/JUnit "just" provides the frame for the test
cases.

Here are some ideas for this DUnit frame (from the previous
DUnit):
- provide means to let a test case pass iff an expected exception
is thrown
- use command-line args to filter test cases to be executed
- add an XML test report for inspection by machines


More information about the Digitalmars-d-announce mailing list