Remove unnecessary toJSON functions, tests