Merge pull request #7438 from mikeller/fix_ledstrip_unit_tests
Fixed unit tests using 'ledstrip.c'.
This commit is contained in:
commit
f097df6fbd
|
@ -286,7 +286,7 @@ void init(void)
|
|||
targetPreInit();
|
||||
#endif
|
||||
|
||||
#if !defined(UNIT_TEST) && !defined(USE_FAKE_LED)
|
||||
#if !defined(USE_FAKE_LED)
|
||||
ledInit(statusLedConfig());
|
||||
#endif
|
||||
LED2_ON;
|
||||
|
|
|
@ -679,11 +679,9 @@ static uint8_t applySelectAdjustment(adjustmentFunction_e adjustmentFunction, ui
|
|||
break;
|
||||
case ADJUSTMENT_LED_PROFILE:
|
||||
#ifdef USE_LED_STRIP
|
||||
#ifndef UNIT_TEST
|
||||
if (getLedProfile() != position) {
|
||||
setLedProfile(position);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
break;
|
||||
|
||||
|
|
|
@ -739,9 +739,11 @@ PG_REGISTER(blackboxConfig_t, blackboxConfig, PG_BLACKBOX_CONFIG, 0);
|
|||
PG_REGISTER(systemConfig_t, systemConfig, PG_SYSTEM_CONFIG, 2);
|
||||
void resetArmingDisabled(void) {}
|
||||
timeDelta_t getTaskDeltaTime(cfTaskId_e) { return 20000; }
|
||||
}
|
||||
armingDisableFlags_e getArmingDisableFlags(void) {
|
||||
return (armingDisableFlags_e) 0;
|
||||
}
|
||||
bool isTryingToArm(void) { return false; }
|
||||
void resetTryingToArm(void) {}
|
||||
void setLedProfile(uint8_t profile) { UNUSED(profile); }
|
||||
uint8_t getLedProfile(void) { return 0; }
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue