tests for Iterable.reduce()