assert that C and TS enum sizes match #3786
is this test testing anything?
This commit is contained in:
parent
96d0a623c0
commit
7850e6e57e
|
@ -18,6 +18,8 @@
|
||||||
static OutputPin alphaEn;
|
static OutputPin alphaEn;
|
||||||
static OutputPin alphaTachPullUp;
|
static OutputPin alphaTachPullUp;
|
||||||
static OutputPin alphaTempPullUp;
|
static OutputPin alphaTempPullUp;
|
||||||
|
static OutputPin alphaCrankPPullUp;
|
||||||
|
static OutputPin alphaCrankNPullUp;
|
||||||
|
|
||||||
static void setInjectorPins() {
|
static void setInjectorPins() {
|
||||||
engineConfiguration->injectionPins[0] = H144_LS_1;
|
engineConfiguration->injectionPins[0] = H144_LS_1;
|
||||||
|
@ -94,6 +96,9 @@ void boardInitHardware() {
|
||||||
alphaEn.setValue(1);
|
alphaEn.setValue(1);
|
||||||
|
|
||||||
alphaTachPullUp.initPin("a-tach", H144_OUT_IO1);
|
alphaTachPullUp.initPin("a-tach", H144_OUT_IO1);
|
||||||
|
alphaTempPullUp.initPin("a-temp", H144_OUT_IO4);
|
||||||
|
alphaCrankPPullUp.initPin("a-crank-p", H144_OUT_IO2);
|
||||||
|
alphaCrankNPullUp.initPin("a-crank-n", H144_OUT_IO5);
|
||||||
}
|
}
|
||||||
|
|
||||||
void setBoardConfigOverrides() {
|
void setBoardConfigOverrides() {
|
||||||
|
|
|
@ -78,8 +78,9 @@ public class ConfigFieldParserTest {
|
||||||
@Test
|
@Test
|
||||||
public void testCustomEnum() throws IOException {
|
public void testCustomEnum() throws IOException {
|
||||||
String test = "struct pid_s\n" +
|
String test = "struct pid_s\n" +
|
||||||
|
"#define ego_sensor_e_size 4\n" +
|
||||||
"#define ego_sensor_e_enum \"BPSX\", \"Innovate\", \"14Point7\"\n" +
|
"#define ego_sensor_e_enum \"BPSX\", \"Innovate\", \"14Point7\"\n" +
|
||||||
"custom ego_sensor_e 4 bits, S32, @OFFSET@, [0:1], @@ego_sensor_e_enum@@\n" +
|
"custom ego_sensor_e @@ego_sensor_e_size@@ bits, S32, @OFFSET@, [0:1], @@ego_sensor_e_enum@@\n" +
|
||||||
"ego_sensor_e afr_type;\n" +
|
"ego_sensor_e afr_type;\n" +
|
||||||
"end_struct\n";
|
"end_struct\n";
|
||||||
ReaderState state = new ReaderState();
|
ReaderState state = new ReaderState();
|
||||||
|
|
Loading…
Reference in New Issue