tests generation code
revert my mess