Named unittests

Jacob Carlborg doob at me.com
Sun May 19 18:58:57 UTC 2019


On 2019-05-19 11:25, Johannes Pfau wrote:

> Now we do have library test runners*. They use compile time reflection to
> find tests, build on UDAs and other well-known language features and I
> really think this is the way to go. In order to switch druntime to such
> an implementation, we would need to reach feature parity with the current
> implementation though. The main problem here is in 1), as reflection
> based runners require you to somehow list all modules which should be
> tested.
> I do not think we want to mess with ModuleInfo here, as this always
> involves serializing compile-time type information to runtime
> information. We want a completely compile time solution here. So what we
> need is some way for a library to reflect on every other application
> module automatically. I'd propose to leverage template mixins for this
> and extend them in one crucial point. Template mixins almost do what we
> want:

Have a look at my reply in a new thread [1].

[1] https://forum.dlang.org/thread/qbs8t1$jo0$1@digitalmars.com

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list