Fix unittest taking a function as an OutputRange