Set up Mockito and simple Unit Test

This commit is contained in:
Keenan D. Buckley
2020-03-28 22:45:44 -06:00
parent e373211f27
commit 489d4a5bff
5 changed files with 62 additions and 4 deletions
+9 -1
View File
@@ -117,7 +117,15 @@ public class RobotGyro extends GyroBase {
* @return heading from -180 to 180 degrees
*/
public double getHeading() {
return Math.IEEEremainder(getAngle(), 360);
return getHeading(getAngle());
}
/**
* Gets an absolute heading of the robot
* @return heading from -180 to 180 degrees
*/
public double getHeading(double angle) {
return Math.IEEEremainder(angle, 360);
}
/**