d4x1 commented on PR #6701:
URL: 
https://github.com/apache/incubator-devlake/pull/6701#issuecomment-1872966384

   > My thoughts:
   > 
   >     * I think `GitRepo` should be turned into an interface with two impls: 
GoGitRepo and LibGitRepo. Refactor the appropriate methods. This creates better 
abstraction and less coupling in the code.
   > 
   >     * Write a temporary main function that uses LibGitRepo to grab data 
from a repo and perform the extraction functions. Capture the output in CSV 
files (like you're doing)
   > 
   >     * Write a test suite that uses GoGitRepo to run the same functions on 
the same repo as above. Test the same functions against the output CSV files 
from above (i.e. compare results).
   > 
   >     * Once all is good, get rid of the LibGitRepo impl and the temporary 
main function.
   
   Turning `GItRepo` into an interface is a good idea! I'll follow your advice.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to