TestGeneration fixes