Run only "unittest", skip "main"
H. S. Teoh via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sat Jan 24 10:52:26 PST 2015
On Sat, Jan 24, 2015 at 06:15:29PM +0000, tcak via Digitalmars-d-learn wrote:
> Is there any way to run only unittest codes, and ignore main function?
>
> DMD is running both of them when I use -unittest.
version(unittest)
{
void main() {}
}
else
{
void main() { /* real main code here */ }
}
T
--
The volume of a pizza of thickness a and radius z can be described by
the following formula: pi zz a. -- Wouter Verhelst
More information about the Digitalmars-d-learn
mailing list