|
19 | 19 | import org.lasarobotics.drive.MAXSwerveModule.GearRatio;
|
20 | 20 | import org.lasarobotics.drive.MAXSwerveModule.ModuleLocation;
|
21 | 21 | import org.lasarobotics.hardware.SparkMax;
|
22 |
| -import org.lasarobotics.hardware.SparkMax.SparkMaxInputs; |
| 22 | +import org.lasarobotics.hardware.SparkMaxInputsAutoLogged; |
23 | 23 | import org.lasarobotics.utils.GlobalConstants;
|
24 | 24 | import org.mockito.AdditionalMatchers;
|
25 | 25 | import org.mockito.ArgumentMatchers;
|
@@ -121,7 +121,7 @@ public void moduleLocation() {
|
121 | 121 | @DisplayName("Test if module can set state")
|
122 | 122 | public void set() {
|
123 | 123 | // Hardcode sensor values
|
124 |
| - SparkMaxInputs sparkMaxInputs = new SparkMaxInputs(); |
| 124 | + SparkMaxInputsAutoLogged sparkMaxInputs = new SparkMaxInputsAutoLogged(); |
125 | 125 | when(m_lFrontRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
126 | 126 | when(m_rFrontRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
127 | 127 | when(m_lRearRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
@@ -150,7 +150,7 @@ public void set() {
|
150 | 150 | @DisplayName("Test if module will auto-lock")
|
151 | 151 | public void autoLock() {
|
152 | 152 | // Hardcode sensor values
|
153 |
| - SparkMaxInputs sparkMaxInputs = new SparkMaxInputs(); |
| 153 | + SparkMaxInputsAutoLogged sparkMaxInputs = new SparkMaxInputsAutoLogged(); |
154 | 154 | when(m_lFrontRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
155 | 155 | when(m_rFrontRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
156 | 156 | when(m_lRearRotateMotor.getInputs()).thenReturn(sparkMaxInputs);
|
@@ -179,8 +179,8 @@ public void autoLock() {
|
179 | 179 | @DisplayName("Test if module works in simulation")
|
180 | 180 | public void simulation() {
|
181 | 181 | // Hardcode sensor values
|
182 |
| - SparkMaxInputs defaultInputs = new SparkMaxInputs(); |
183 |
| - SparkMaxInputs lFrontRotateMotorInputs = new SparkMaxInputs(); |
| 182 | + SparkMaxInputsAutoLogged defaultInputs = new SparkMaxInputsAutoLogged(); |
| 183 | + SparkMaxInputsAutoLogged lFrontRotateMotorInputs = new SparkMaxInputsAutoLogged(); |
184 | 184 | lFrontRotateMotorInputs.absoluteEncoderPosition = ModuleLocation.LeftFront.offset.getRadians();
|
185 | 185 | when(m_lFrontDriveMotor.getInputs()).thenReturn(defaultInputs);
|
186 | 186 | when(m_lFrontRotateMotor.getInputs()).thenReturn(lFrontRotateMotorInputs);
|
|
0 commit comments