|
Unit/Integration testing JAva code for FRC
Our programming team is typically made of ~8 students and two mentors. We manage our code in github projects. Our workflow is usually something like the following: Students are assigned development of specific functionality (subsystems/commands). They develop this code in a branch, commit their changes to the branches, and when they are done they submit a pull request. A mentor or lead student reviews the changes and make comments if there are problems. Once the code is deemed complete it gets pulled into our master branch. Master is the branch which should always be safe to deploy to the hardware.
We have had success with this workflow over the past few years, but it's completely dependent upon good 'peer review' of code to catch problems before getting pulled into Master. Inevitably, people are going to miss bugs, especially when it comes to integration of classes (e.g. command passes in a negative value to drive a motor forward, but the method being called requires a positive value to do that).
Last year we ran into a few problems with code changes getting pulled into our master branch which, that when integrated with other units, didn't work correctly.
There weren't any show stoppers, but I don't want to depend on impeccable code review from a few select individuals to find all the problems, especially when changes are being made at competition.
I'm interested in knowing what experiences other teams have with unit/integration test tools.
What have you used?
What has/hasn't worked and why?
Links to code/examples of your tool of choice in use would be appreciated.
Thanks!
|