Test data generation code