Helper function for constructing posttest loops as an expression.
Calls state.checkTime() on every iteration.
None
nothing