Removing autogenenated files
Added getfields test and fixed bug