technical debt: NT -> US -> NT in unit test scheduler [update tests]
see #7245
This commit is contained in:
parent
44f33b0579
commit
bd66c1b602
|
@ -30,6 +30,8 @@ static void doRevolution(EngineTestHelper& eth, int periodMs) {
|
|||
|
||||
// https://github.com/rusefi/rusefi/issues/1592
|
||||
TEST(fuelControl, transitionIssue1592) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineTestHelper eth(engine_type_e::TEST_ENGINE);
|
||||
engine->tdcMarkEnabled = false;
|
||||
setupSimpleTestEngineWithMafAndTT_ONE_trigger(ð, IM_SEQUENTIAL);
|
||||
|
|
|
@ -46,6 +46,8 @@ TEST(ignition, twoCoils) {
|
|||
}
|
||||
|
||||
TEST(ignition, trailingSpark) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineTestHelper eth(engine_type_e::TEST_ENGINE);
|
||||
engineConfiguration->isFasterEngineSpinUpEnabled = false;
|
||||
|
||||
|
|
|
@ -17,6 +17,8 @@ static void assertToggleCounterExtra(EngineTestHelper *eth, size_t extra, const
|
|||
}
|
||||
|
||||
TEST(HPFP, IntegratedSchedule) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineTestHelper eth(engine_type_e::TEST_ENGINE, [](engine_configuration_s* engineConfiguration) {
|
||||
engineConfiguration->hpfpValvePin = Gpio::A2; // arbitrary
|
||||
});
|
||||
|
|
|
@ -48,6 +48,8 @@ static void prepareToScheduleOverdwellSparkDown(EngineTestHelper& eth) {
|
|||
}
|
||||
|
||||
TEST(coil, testOverdwellProtection) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
printf("*************************************************** testOverdwellProtection\r\n");
|
||||
|
||||
EngineTestHelper eth(engine_type_e::TEST_ENGINE);
|
||||
|
|
|
@ -70,6 +70,8 @@ static void scheduleTriggerEvents(TriggerWaveform *shape,
|
|||
|
||||
|
||||
TEST(nissan, vq_vvt) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
// hold a reference to the heap allocated scheduling events until the test is done
|
||||
std::vector<std::shared_ptr<TriggerCallback>> ptrs;
|
||||
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
#include "engine_csv_reader.h"
|
||||
|
||||
TEST(real4b11, running) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineCsvReader reader(1, /* vvtCount */ 0);
|
||||
|
||||
reader.open("tests/trigger/resources/4b11-running.csv");
|
||||
|
@ -30,6 +32,8 @@ TEST(real4b11, running) {
|
|||
}
|
||||
|
||||
TEST(real4b11, runningDoubledEdge) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineCsvReader reader(1, /* vvtCount */ 0);
|
||||
|
||||
// This log has an extra duplicate edge at 5.393782 seconds (hand added)
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
#include "logicdata_csv_reader.h"
|
||||
|
||||
TEST(arctic, realStartFromFile) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
CsvReader reader(1, /* vvtCount */ 0);
|
||||
|
||||
reader.open("tests/trigger/resources/arctic-cat.csv");
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
#include "engine_csv_reader.h"
|
||||
|
||||
TEST(realCas24Plus1, spinningOnBench) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineCsvReader reader(/*triggerCount*/1, /* vvtCount */ 1);
|
||||
|
||||
reader.open("tests/trigger/resources/cas_nissan_24_plus_1.csv");
|
||||
|
|
|
@ -28,7 +28,9 @@ TEST(fordCoyote, intakeCam) {
|
|||
}
|
||||
|
||||
TEST(fordCoyote, intakeCamInverted) {
|
||||
runCoyoteIntakeCam(true, 3, 1018);
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
runCoyoteIntakeCam(true, 3, 1018);
|
||||
}
|
||||
|
||||
static void runCoyoteExhaustCam(bool invertPrimaryTriggerSignal, int warningCount, int rpm) {
|
||||
|
@ -56,5 +58,7 @@ TEST(fordCoyote, exhaustCam) {
|
|||
}
|
||||
|
||||
TEST(fordCoyote, exhaustCamInverted) {
|
||||
runCoyoteExhaustCam(true, 2, 1046);
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
runCoyoteExhaustCam(true, 2, 1046);
|
||||
}
|
||||
|
|
|
@ -10,6 +10,8 @@
|
|||
#include "logicdata_csv_reader.h"
|
||||
|
||||
TEST(crankingVW, vwRealCrankingFromFile) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
CsvReader reader(1, /* vvtCount */ 0);
|
||||
|
||||
reader.open("tests/trigger/resources/nick_1.csv");
|
||||
|
@ -26,6 +28,8 @@ TEST(crankingVW, vwRealCrankingFromFile) {
|
|||
}
|
||||
|
||||
TEST(crankingVW, crankingTwiceWithGap) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
EngineTestHelper eth (engine_type_e::VW_ABA);
|
||||
engineConfiguration->alwaysInstantRpm = true;
|
||||
eth.setTriggerType(trigger_type_e::TT_60_2_WRONG_POLARITY);
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
#include "logicdata_csv_reader.h"
|
||||
|
||||
TEST(Toyota3ToothCam, RealEngineRunning) {
|
||||
extern bool unitTestTaskPrecisionHack;
|
||||
unitTestTaskPrecisionHack = true;
|
||||
CsvReader reader(1, /* vvtCount */ 1);
|
||||
|
||||
reader.open("tests/trigger/resources/toyota_3_tooth_cam.csv");
|
||||
|
|
Loading…
Reference in New Issue