Fix warnings in automatically generated tests