Closed tinloaf closed 6 years ago
There is a lot of code here. Let me look at it for a bit. You did your pull request against "master", you should have done it against "develop" instead. (Following GitFlow). I am wondering out loud if making measurements generic from the start (of which, timing is the default option) is something that might work.
Ok. I've looked this over. I think this is a reasonable implementation for now. It's a bit shoe-horned in, but the code just isn't built from the ground up to do this. I'm thinking about adding this concept to the next major version of Celero so that it can make arbitrary measurements. For now, I'm going to add your code in myself with some updates. For now, I'm going to reject your pull request, but look for this to be implemented on the Develop branch soon. I'll post a note here when that is done. (I'm working on it now.)
Thanks for this great contribution!
This code was manually merged and updated onto the develop
branch.
Great, thanks! :-) Do you know when this will make it into a release (one of my projects is depending on it, and it would be kind of bad if I depended on the development branch…)?
This is a first attempt at what I suggested in https://github.com/DigitalInBlue/Celero/issues/126
It has become a larger change than I expected, but that's also because I needed to change a lot in the printing code to accommodate for the new columns. I haven't yet added output of the user-defined measurements in the other two formats; this will follow if you like what I have so far.
There are some points which I'm not completely happy with, but for which I don't see a perfect solution:
Celero.cpp
, however it also doesn't fit intoExecutor.cpp
- or anywhere else, really. Maybe this should be part of theUDMCollector
?UDMCollector
itself feels a bit like it should be part ofExperimentResult
. However, at the time theExperimentResult
objects are created, we don't have theTestFixture
objects yet (which I need for theUDMCollector
…)Also, I didn't find any specification of what code style you prefer. I tried to go with what I found and keep it consistent.