generation code test