Formatting fixes.
Actually use the resultType of the Aggregation
More tests for aggregations that return a different result type.