Constructor tests added for Generator, mergeFunctions, mergeFunction and functionStatistics

- Return handler constructor empty, so no tests needed
- Messages now handle errors instead of just console messages
- sameStructure test to check if 2 objects properties sets are equivalent