0

Everytime an user is updating a particular unit (or a particular classe), I want to raise an error or show a warning. The purpose is to warn the developer to not forget to update the DUnit tests. My idea is to make a hash of the dcu (or the classe) and compare with the previous hash we had. the problem is that at run time I do not have access to the .pas so I must generate this "hash" without any access to the .pas and I don't know if it's feasible.

zeus
  • 12,173
  • 9
  • 63
  • 184
  • Is a "post build" command not what you are looking for? You can run your hashing generator after each build and trigger a warning for the developer. – fpiette Jul 26 '22 at 09:49
  • If you do have access to the DCU, an alternative could be a directory monitor. These can detect changes and react in many different ways. – MyICQ Jul 26 '22 at 13:15
  • @fpiette thanks yes it's a way, but I would from inside the app do this. I will look If I can not make a "hash" of the classe with the help of the RTTI – zeus Jul 27 '22 at 07:28
  • Do this from inside which app? – David Heffernan Jul 27 '22 at 08:26

0 Answers0