Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR wants to implement the issues #990 and #1001 .
Maybe it is not yet completed, but I think it is time for a review.
Please note:
Timing issues
I implemented new functionality which is related to timing. Unfortunately this cause failed tests from time to time because the real timing cannot be setup as exact as required (without creating real slow tests).
I already have seen some other tests which have the same problem. But I have no (easy) idea yet, how to get the problem fixed.
I think it will only work if the timing is fully mocked. We could introduce a new internal interface like that:
Maybe you know already a good abstraction for the timer.
Anyway, the full solution is a new issue, I guess.
Unit test method naming
I added several unit tests for the new functions. But for me, your naming style for the test methods is completely new (never seen before).
I tried to build names according to the existing tests. Hopefully it is ok. Otherwise please tell me the correct names or even better: Please just rename the tests directly, if needed.
BTW: What do you think about the popular style [UnitOfWork_StateUnderTest_ExpectedBehavior]?