hijack dub test
Jacob Carlborg via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu Aug 31 00:04:13 PDT 2017
On 2017-08-31 08:41, Nicholas Wilson wrote:
> My project is a library, but I also need to test it and unit tests won't
> cut it (external hardware).
>
> How do you set up the dub.json to build the library normally but when it
> is invoked with `dub test` it runs a separate configuration that also
> includes files in the `source/test` folder, but are excluded when not
> testing.
"The configuration name "unittest" has a special meaning - if a
configuration with this name is present, it will be used by default when
executing dub test." [1]
[1] http://code.dlang.org/package-format?lang=json#configurations
--
/Jacob Carlborg
More information about the Digitalmars-d-learn
mailing list