mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
Reduced duplication between formatting scripts with Task base class (#80)
Also added scripts for EOF newline management and for removing trailing whitespace. configure.bat was rewritten to use CRLF line endings. Documentation for the existing scripts was also improved.
This commit is contained in:
committed by
Peter Johnson
parent
ea6876e81f
commit
aafca4ed7f
@@ -35,7 +35,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testDigitalChannels() {
|
||||
assertEquals(26, SensorBase.kDigitalChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kAnalogInputChannels.
|
||||
*/
|
||||
@@ -43,7 +43,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testAnalogInputChannels() {
|
||||
assertEquals(8, SensorBase.kAnalogInputChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kAnalogOutputChannels.
|
||||
*/
|
||||
@@ -51,7 +51,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testAnalogOutputChannels() {
|
||||
assertEquals(2, SensorBase.kAnalogOutputChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kSolenoidChannels.
|
||||
*/
|
||||
@@ -59,7 +59,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testSolenoidChannels() {
|
||||
assertEquals(8, SensorBase.kSolenoidChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kPwmChannels.
|
||||
*/
|
||||
@@ -67,7 +67,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testPwmChannels() {
|
||||
assertEquals(20, SensorBase.kPwmChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kRelayChannels.
|
||||
*/
|
||||
@@ -75,7 +75,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testRelayChannels() {
|
||||
assertEquals(8, SensorBase.kRelayChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kPDPChannels.
|
||||
*/
|
||||
@@ -83,7 +83,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testPDPChannels() {
|
||||
assertEquals(16, SensorBase.kPDPChannels);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kPDPModules.
|
||||
*/
|
||||
@@ -91,7 +91,7 @@ public class ConstantsPortsTest extends AbstractComsSetup {
|
||||
public void testPDPModules() {
|
||||
assertEquals(63, SensorBase.kPDPModules);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* kPCMModules.
|
||||
*/
|
||||
|
||||
@@ -20,8 +20,8 @@ import edu.wpi.first.wpilibj.test.AbstractTestSuite;
|
||||
@RunWith(Suite.class)
|
||||
@SuiteClasses({AnalogCrossConnectTest.class, AnalogPotentiometerTest.class,
|
||||
BuiltInAccelerometerTest.class, CANTalonTest.class,
|
||||
CircularBufferTest.class, ConstantsPortsTest.class, CounterTest.class,
|
||||
DigitalGlitchFilterTest.class, DIOCrossConnectTest.class, EncoderTest.class,
|
||||
CircularBufferTest.class, ConstantsPortsTest.class, CounterTest.class,
|
||||
DigitalGlitchFilterTest.class, DIOCrossConnectTest.class, EncoderTest.class,
|
||||
FilterNoiseTest.class, FilterOutputTest.class, GyroTest.class, MotorEncoderTest.class,
|
||||
MotorInvertingTest.class, PCMTest.class, PDPTest.class, PIDTest.class,
|
||||
PIDToleranceTest.class, PreferencesTest.class, RelayCrossConnectTest.class,
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
/* Copyright (c) FIRST 2016. All Rights Reserved. */
|
||||
/* Open Source Software - may be modified and shared by FRC teams. The code */
|
||||
/* must be accompanied by the FIRST BSD license file in the root directory of */
|
||||
/* the project. */
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
/**
|
||||
* Provides a suite of tests to cover CANJaguar fully in all different control modes and with each
|
||||
* supported positional input. Different setup parameters are provided in each Test class. All test
|
||||
|
||||
@@ -129,18 +129,18 @@ public abstract class FilterOutputFixture<T extends PIDSource> implements ITestF
|
||||
@SuppressWarnings("ParameterName")
|
||||
public abstract double getData(double t);
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public void setPIDSourceType(PIDSourceType pidSource) {
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public PIDSourceType getPIDSourceType() {
|
||||
return PIDSourceType.kDisplacement;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public double pidGet() {
|
||||
m_count += TestBench.kFilterStep;
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
/* Copyright (c) FIRST 2016. All Rights Reserved. */
|
||||
/* Open Source Software - may be modified and shared by FRC teams. The code */
|
||||
/* must be accompanied by the FIRST BSD license file in the root directory of */
|
||||
/* the project. */
|
||||
/*----------------------------------------------------------------------------*/
|
||||
|
||||
/**
|
||||
* This is the starting point for the integration testing framework. This package should contain
|
||||
* classes that are not explicitly for testing the library but instead provide the framework that
|
||||
|
||||
Reference in New Issue
Block a user