test(gen): clean up code and test more endpoint combinations

Changes:
- remove unneeded code
- use runTest for endpoints as well
- test endpoints with different options
- test endpoints with various cased named

Exposes Bug:
See #540
Merge pull request #542 from kingcody/refactor/gen-tests

test(gen): clean up code and test more endpoint combinations