diff --git a/java_console/autotest/src/main/java/com/rusefi/f4discovery/CommonFunctionalTest.java b/java_console/autotest/src/main/java/com/rusefi/f4discovery/CommonFunctionalTest.java index 219b86c9b4..a18152ee13 100644 --- a/java_console/autotest/src/main/java/com/rusefi/f4discovery/CommonFunctionalTest.java +++ b/java_console/autotest/src/main/java/com/rusefi/f4discovery/CommonFunctionalTest.java @@ -4,6 +4,7 @@ package com.rusefi.f4discovery; import com.rusefi.RusefiTestBase; import com.rusefi.core.Sensor; import com.rusefi.core.SensorCentral; +import com.rusefi.enums.SensorType; import com.rusefi.enums.engine_type_e; import com.rusefi.functional_tests.EcuTestHelper; import com.rusefi.waves.EngineChart; @@ -113,7 +114,7 @@ public class CommonFunctionalTest extends RusefiTestBase { // Alpha-N mode so that we actually inject some fuel (without mocking tons of sensors) ecu.sendCommand("set algorithm 2"); // Set tps to 25% - make alpha-n happy - ecu.sendCommand("set_sensor_mock 10 25"); + ecu.sendCommand("set_sensor_mock " + SensorType.Tps1.ordinal() + " 25"); ecu.sendCommand("set rpm_hard_limit 2500"); { @@ -204,8 +205,8 @@ public class CommonFunctionalTest extends RusefiTestBase { ecu.setEngineType(engine_type_e.DODGE_NEON_2003_CRANK); ecu.sendCommand("set wwaeTau 0"); ecu.sendCommand("set wwaeBeta 0"); - ecu.sendCommand("set_sensor_mock 4 69.12"); // MAP - ecu.sendCommand("set_sensor_mock 27 12"); + ecu.sendCommand("set_sensor_mock " + SensorType.Map.ordinal() + " 69.12"); + ecu.sendCommand("set_sensor_mock " + SensorType.BatteryVoltage.ordinal() + " 12"); ecu.sendCommand("disable cylinder_cleanup"); EngineChart chart; String msg = "2003 Neon cranking "; @@ -270,12 +271,12 @@ public class CommonFunctionalTest extends RusefiTestBase { public void testMazdaProtege() { ecu.setEngineType(engine_type_e.FORD_ESCORT_GT); EngineChart chart; - ecu.sendCommand("set_sensor_mock 27 12"); + ecu.sendCommand("set_sensor_mock " + SensorType.BatteryVoltage.ordinal() + " 12"); // Alpha-N mode so that we actually inject some fuel (without mocking tons of sensors) ecu.sendCommand("set algorithm 2"); // Set tps to 25% - make alpha-n happy - ecu.sendCommand("set_sensor_mock 10 25"); + ecu.sendCommand("set_sensor_mock " + SensorType.Tps1.ordinal() + " 25"); ecu.changeRpm(200); ecu.changeRpm(260); @@ -320,7 +321,7 @@ public class CommonFunctionalTest extends RusefiTestBase { assertWaveNotNull(msg, chart, EngineChart.SPARK_3); // switching to Speed Density - ecu.sendCommand("set_sensor_mock 4 69.12"); // MAP + ecu.sendCommand("set_sensor_mock " + SensorType.Map.ordinal() + " 69.12"); sendComplexCommand("set algorithm 0"); ecu.changeRpm(2600); ecu.changeRpm(2000); @@ -349,8 +350,8 @@ public class CommonFunctionalTest extends RusefiTestBase { public void testFordAspire() { ecu.setEngineType(engine_type_e.FORD_ASPIRE_1996); ecu.sendCommand("disable cylinder_cleanup"); - ecu.sendCommand("set_sensor_mock 4 69.12"); // MAP - ecu.sendCommand("set_sensor_mock 27 12"); // vbatt + ecu.sendCommand("set_sensor_mock " + SensorType.Map.ordinal() + " 69.12"); + ecu.sendCommand("set_sensor_mock " + SensorType.BatteryVoltage.ordinal() + " 12"); String msg; EngineChart chart; // todo: interesting changeRpm(100);