mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-21 01:01:43 +00:00
Checkstyle 8.1 (#584)
Added a few checks too: - SimplifyBooleanExpression - SimplifyBooleanReturn - StringLiteralEquality - UnnecessaryParentheses
This commit is contained in:
committed by
Peter Johnson
parent
3cfcbe9a95
commit
ddd5aeba19
@@ -96,12 +96,12 @@ public class PIDToleranceTest {
|
||||
assertFalse("Error was in tolerance when it should not have been. Error was "
|
||||
+ m_pid.getAvgError(), m_pid.onTarget());
|
||||
//half of percent tolerance away from setPoint
|
||||
m_inp.m_val = m_setPoint + (m_tolerance) / 200 * m_range;
|
||||
m_inp.m_val = m_setPoint + m_tolerance / 200 * m_range;
|
||||
Timer.delay(1.0);
|
||||
assertTrue("Error was not in tolerance when it should have been. Error was "
|
||||
+ m_pid.getAvgError(), m_pid.onTarget());
|
||||
//double percent tolerance away from setPoint
|
||||
m_inp.m_val = m_setPoint + (m_tolerance) / 50 * m_range;
|
||||
m_inp.m_val = m_setPoint + m_tolerance / 50 * m_range;
|
||||
Timer.delay(1.0);
|
||||
assertFalse("Error was in tolerance when it should not have been. Error was "
|
||||
+ m_pid.getAvgError(), m_pid.onTarget());
|
||||
|
||||
@@ -70,6 +70,8 @@ public class MockCommand extends Command {
|
||||
}
|
||||
|
||||
/**
|
||||
* Get what value the isFinished method will return.
|
||||
*
|
||||
* @return what value the isFinished method will return.
|
||||
*/
|
||||
public boolean isHasFinished() {
|
||||
@@ -77,6 +79,8 @@ public class MockCommand extends Command {
|
||||
}
|
||||
|
||||
/**
|
||||
* Set what value the isFinished method will return.
|
||||
*
|
||||
* @param hasFinished set what value the isFinished method will return.
|
||||
*/
|
||||
public void setHasFinished(boolean hasFinished) {
|
||||
|
||||
Reference in New Issue
Block a user