test(index): Use `typeof` to check the type.
test(index): Use `typeof` to check the type.

 * Should check `GeneratorFunction` instead of `function`.
 As newest version of node actually support this
 function type 🎉, but it will break in older node versions.

alvaropinot/circular-iterator