Skip to content

Commit 060b883

Browse files
mprsecmonr
authored andcommitted
Modify ticker_init_test() to be consistent with the new requirement.
1 parent b1e41ff commit 060b883

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

TESTS/mbed_hal/lp_us_tickers/main.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ void wait_cycles(volatile unsigned int cycles)
9292
}
9393

9494
/* Test that ticker_init can be called multiple times and
95-
* ticker_init resets the internal count and disables the ticker interrupt.
95+
* ticker_init allows the ticker to keep counting and disables the ticker interrupt.
9696
*/
9797
void ticker_init_test()
9898
{
@@ -118,7 +118,7 @@ void ticker_init_test()
118118
}
119119

120120
TEST_ASSERT(intf->read() >= (ticks_start + 2 * TICKER_INT_VAL));
121-
TEST_ASSERT(ticks_start > ticks_after_reinit);
121+
TEST_ASSERT(ticks_start <= ticks_after_reinit);
122122
TEST_ASSERT_EQUAL(0, intFlag);
123123
}
124124

TESTS/mbed_hal/lp_us_tickers/ticker_api_tests.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ extern "C" {
3232
*
3333
* Given ticker is initialised and interrupt is set.
3434
* When ticker is re-initialised.
35-
* Then ticker resets the internal count and disables the ticker interrupt.
35+
* Then ticker keeps counting and disables the ticker interrupt.
3636
*/
3737
void ticker_init_test(void);
3838

0 commit comments

Comments
 (0)