mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 00:05:33 +03:00
Post rebase fixup.
This commit is contained in:
parent
32c4348357
commit
01a19cdc04
3 changed files with 1 additions and 15 deletions
|
@ -20,9 +20,6 @@
|
||||||
#ifdef SRC_MAIN_SCHEDULER_C_
|
#ifdef SRC_MAIN_SCHEDULER_C_
|
||||||
#ifdef UNIT_TEST
|
#ifdef UNIT_TEST
|
||||||
|
|
||||||
#ifdef SRC_MAIN_SCHEDULER_C_
|
|
||||||
#ifdef UNIT_TEST
|
|
||||||
|
|
||||||
cfTask_t *unittest_scheduler_selectedTask;
|
cfTask_t *unittest_scheduler_selectedTask;
|
||||||
uint8_t unittest_scheduler_selectedTaskDynamicPriority;
|
uint8_t unittest_scheduler_selectedTaskDynamicPriority;
|
||||||
uint16_t unittest_scheduler_waitingTasks;
|
uint16_t unittest_scheduler_waitingTasks;
|
||||||
|
|
|
@ -61,7 +61,7 @@ static cfTask_t* taskQueueArray[TASK_COUNT + 1]; // extra item for NULL pointer
|
||||||
#endif
|
#endif
|
||||||
STATIC_UNIT_TESTED void queueClear(void)
|
STATIC_UNIT_TESTED void queueClear(void)
|
||||||
{
|
{
|
||||||
memset(taskQueueArray, 0, (int)(sizeof(taskQueueArray)));
|
memset(taskQueueArray, 0, sizeof(cfTask_t) * (TASK_COUNT + 1));
|
||||||
taskQueuePos = 0;
|
taskQueuePos = 0;
|
||||||
taskQueueSize = 0;
|
taskQueueSize = 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -83,17 +83,6 @@ extern "C" {
|
||||||
extern cfTask_t *queueNext(void);
|
extern cfTask_t *queueNext(void);
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST(SchedulerUnittest, TestPriorites)
|
|
||||||
{
|
|
||||||
// check that the #defines used by scheduler.c and scheduler_unittest.cc are in sync
|
|
||||||
EXPECT_EQ(14, TASK_COUNT);
|
|
||||||
EXPECT_EQ(TASK_PRIORITY_HIGH, cfTasks[TASK_SYSTEM].staticPriority);
|
|
||||||
EXPECT_EQ(TASK_PRIORITY_REALTIME, cfTasks[TASK_GYROPID].staticPriority);
|
|
||||||
EXPECT_EQ(TASK_PRIORITY_MEDIUM, cfTasks[TASK_ACCEL].staticPriority);
|
|
||||||
EXPECT_EQ(TASK_PRIORITY_LOW, cfTasks[TASK_SERIAL].staticPriority);
|
|
||||||
EXPECT_EQ(TASK_PRIORITY_MEDIUM, cfTasks[TASK_BATTERY].staticPriority);
|
|
||||||
}
|
|
||||||
|
|
||||||
TEST(SchedulerUnittest, TestPriorites)
|
TEST(SchedulerUnittest, TestPriorites)
|
||||||
{
|
{
|
||||||
EXPECT_EQ(14, TASK_COUNT);
|
EXPECT_EQ(14, TASK_COUNT);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue