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.
It struck me that test five would be a stronger test if it also evaluated whether rates other than unity produced expected output. I thus tinkered (quickly) with the source as below, to see whether a rate of 2 would lead to double the change. (I'm not sure that this is necessarily a linear relationship, but it's probably a good enough approximation for these purposes.)
I saw a few things I didn't understand:
The test passed when I ran it within Qt:
If I changed the pass conditions to guarantee a failure, test five passed, whilst test eighteen failed (?) – output below
The test failed when I built and deployed the software (which seems to contradict the assertion I think I recall seeing elsewhere that the software couldn't be built if tests were failing).