Wrap the generate method in unit tests.