The title pretty much sums it up: I tried to use assertEqual to test a function that returns a generator object, but that results in:
AssertionError: gene
Use next() on the generator object.
next()
assertEqual(next(generator_object), (1, 2, ...))