Skip to content

Commit

Permalink
Merge branch 'master' into nms/monitor-vs-average-reduntant-sensor
Browse files Browse the repository at this point in the history
  • Loading branch information
mck1117 authored Jul 13, 2024
2 parents 68cee90 + d37a5c1 commit 95bd84b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion firmware/controllers/date_stamp.h
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#pragma once
#define VCS_DATE 20240712
#define VCS_DATE 20240713
12 changes: 6 additions & 6 deletions unit_tests/engine_test_helper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -219,12 +219,12 @@ void EngineTestHelper::smartFireTriggerEvents2(int count, float durationMs) {
}

void EngineTestHelper::clearQueue() {
engine.executor.executeAll(99999999); // this is needed to clear 'isScheduled' flag
ASSERT_EQ( 0, engine.executor.size()) << "Failed to clearQueue";
engine.scheduler.executeAll(99999999); // this is needed to clear 'isScheduled' flag
ASSERT_EQ( 0, engine.scheduler.size()) << "Failed to clearQueue";
}

int EngineTestHelper::executeActions() {
return engine.executor.executeAll(getTimeNowUs());
return engine.scheduler.executeAll(getTimeNowUs());
}

void EngineTestHelper::moveTimeForwardMs(float deltaTimeMs) {
Expand Down Expand Up @@ -258,7 +258,7 @@ void EngineTestHelper::moveTimeForwardAndInvokeEventsUs(int deltaTimeUs) {

void EngineTestHelper::setTimeAndInvokeEventsUs(int targetTime) {
while (true) {
scheduling_s* nextScheduledEvent = engine.executor.getHead();
scheduling_s* nextScheduledEvent = engine.scheduler.getHead();
if (nextScheduledEvent == nullptr) {
// nothing pending - we are done here
break;
Expand All @@ -269,7 +269,7 @@ void EngineTestHelper::setTimeAndInvokeEventsUs(int targetTime) {
break;
}
setTimeNowUs(nextEventTime);
engine.executor.executeAll(getTimeNowUs());
engine.scheduler.executeAll(getTimeNowUs());
}

setTimeNowUs(targetTime);
Expand All @@ -290,7 +290,7 @@ void EngineTestHelper::assertInjectorDownEvent(const char *msg, int eventIndex,
}

scheduling_s * EngineTestHelper::assertEvent5(const char *msg, int index, void *callback, efitimeus_t expectedTimestamp) {
TestExecutor *executor = &engine.executor;
TestExecutor *executor = &engine.scheduler;
EXPECT_TRUE(executor->size() > index) << msg << " valid index";
scheduling_s *event = executor->getForUnitTest(index);
assertEqualsM4(msg, " callback up/down", (void*)event->action.getCallback() == (void*) callback, 1);
Expand Down

0 comments on commit 95bd84b

Please sign in to comment.