Errors compiling DSSS

Dmitry Olshansky dmitry.olsh at gmail.com
Fri Nov 30 10:36:37 PST 2012


11/30/2012 12:05 PM, Jacob Carlborg пишет:
> On 2012-11-29 23:06, Rob T wrote:
>
>> For the moment, let's talk about ddoc, or unit testing in D. That's the
>> difference, it's not an external tool set, it's instead a a part of the
>> standard language feature set. BTW, IMO ddoc was implemented poorly,
>> using comments, which I fully agree with you would be a vary bad way to
>> go about implementing the feature. In that case, I would rather use Ruby.
>
> The built-in support for unit testing is too simplistic. I think one
> needs an external tool anyway that makes use of the built-in support
> unit tests.
>
> I just want to be able to do something like:
>
> $ test a.d b.d
>
> And it will run all unit tests in the modules "a" and "b". In D I need
> to manually creating a test module which imports all modules I want to
> test.

AFAIK you don't need to import module to run its tests. So
    rdmd --main -unittest a.d b.d
should work.

Then we should also be able to make rdmd more extendable. There is e.g. 
quite interesting --eval switch but I feel it could be something more 
customizable w/o a lot of extra work.

>This will give the most basic functionality. This is a few things
> of that's missing:
>
> * Run a single test
> * Names or context for the tests
> * Nice report of which tests failed
> * Continue running other tests if a given test failed
>

-- 
Dmitry Olshansky


More information about the Digitalmars-d mailing list