fluent/fluentd — pull request #414 by itiut (2014-08-19 11:04:10+00:00)
Title: Can register conditions in which the loop continues/exits

Add two types of loop conditions that can be registered as lambda expressions:

* Post conditions: conditions that will have to be all satisfied at the end of the loop if the loop ends normally.
* Breaking conditions: conditions that is used to exit the loop.

The loop in InputTestDriver#run stops if all of the post conditions are satisfied or any of the breaking conditions is satisfied.
To avoid infinite loops caused by some errors or incorrect post conditions, breaking conditions are prior to post conditions and InputTestDriver set timeout as a breaking condition.

This can be used to set loop conditions more flexibly than #397, in which only the length of expected emits can be set as a post condition.
To be honest, I am writing codes about #408 and it is not sufficient to set only the length of expected emits as a post condition to write test codes.

The names of these conditions sounds a bit strange to me, but I cannot think of better ones. How do you think of these names?