mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-25 01:41:43 +00:00
Implements AutoCloseable for types, replacing free() (#1048)
This commit is contained in:
committed by
Peter Johnson
parent
a2ecb1027a
commit
cbaff52850
@@ -78,7 +78,7 @@ public class AnalogCrossConnectTest extends AbstractInterruptTest {
|
||||
assertFalse("Analog trigger is in the window (2V, 3V)", trigger.getInWindow());
|
||||
assertFalse("Analog trigger is on", trigger.getTriggerState());
|
||||
|
||||
trigger.free();
|
||||
trigger.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -95,7 +95,7 @@ public class AnalogCrossConnectTest extends AbstractInterruptTest {
|
||||
assertTrue("Analog trigger is not in the window (2V, 3V)", trigger.getInWindow());
|
||||
assertFalse("Analog trigger is on", trigger.getTriggerState());
|
||||
|
||||
trigger.free();
|
||||
trigger.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -112,7 +112,7 @@ public class AnalogCrossConnectTest extends AbstractInterruptTest {
|
||||
assertFalse("Analog trigger is in the window (2V, 3V)", trigger.getInWindow());
|
||||
assertTrue("Analog trigger is not on", trigger.getTriggerState());
|
||||
|
||||
trigger.free();
|
||||
trigger.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -167,9 +167,9 @@ public class AnalogCrossConnectTest extends AbstractInterruptTest {
|
||||
@Override
|
||||
void freeInterruptableSensorBase() {
|
||||
m_interruptTriggerOutput.cancelInterrupts();
|
||||
m_interruptTriggerOutput.free();
|
||||
m_interruptTriggerOutput.close();
|
||||
m_interruptTriggerOutput = null;
|
||||
m_interruptTrigger.free();
|
||||
m_interruptTrigger.close();
|
||||
m_interruptTrigger = null;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user