Follow up for 0426552.
This commit is contained in:
@@ -43,8 +43,9 @@ TEST_CASE("Relay channels initialize correctly to FREE state", "[relay_chn]") {
|
|||||||
|
|
||||||
// TEST_CASE 1: Test that relays do nothing when an invlid channel id given
|
// TEST_CASE 1: Test that relays do nothing when an invlid channel id given
|
||||||
TEST_CASE("Run forward does nothing if channel id is invalid", "[relay_chn]") {
|
TEST_CASE("Run forward does nothing if channel id is invalid", "[relay_chn]") {
|
||||||
for (uint8_t i = relay_chn_count*2; i < relay_chn_count; i++) {
|
for (uint8_t i = 0; i < relay_chn_count; i++) {
|
||||||
relay_chn_run_forward(i); // relay_chn_run_forward returns void
|
int invalid_id = relay_chn_count * 2 + i;
|
||||||
|
relay_chn_run_forward(invalid_id); // relay_chn_run_forward returns void
|
||||||
// Short delay for state to update
|
// Short delay for state to update
|
||||||
vTaskDelay(pdMS_TO_TICKS(test_delay_margin_ms));
|
vTaskDelay(pdMS_TO_TICKS(test_delay_margin_ms));
|
||||||
TEST_ASSERT_EQUAL(RELAY_CHN_STATE_FREE, relay_chn_get_state(i));
|
TEST_ASSERT_EQUAL(RELAY_CHN_STATE_FREE, relay_chn_get_state(i));
|
||||||
|
|||||||
Reference in New Issue
Block a user