On Thursday, 25 September 2014 at 13:50:10 UTC, Jacob Carlborg
wrote:
On 25/09/14 09:38, Atila Neves wrote:
Here's one: having to manually generate the custom main file
for
unittest builds. There's no current way (or at least there
wasn't when I
brought it up in the dub forum) to tell it to autogenerate a D
file from
a dub package and list it as a dependency of the unittest
build.
Hmm, I haven't used Dub to run unit tests. Although, DMD has a
"-main" flag that adds an empty main function.
Andrei spoke about an idiom that they constantly use at Facebok,
because there aparrently nobody runs *main and unittests*. So
they keep a special empty main for the -unittest version.
If tha time to clean up D has come, maybe it is the time to make
that idiom the default behaviour of the flag. He posted that
thing somewhere in the forum, but cannot find it right now.
Real usage is good for learning.