Skip to content

Commit 86dab2f

Browse files
committed
Disable time drifting test cases.
Time drifting test cases use serial communication with the host and are unstable on CI. Skip time-drifting test cases if SKIP_TIME_DRIFT_TESTS macro is defined. The idea for the future is to use FPGA test shield for timing tests instead of host scripts. Also remove `__ARM_FM` macro which in most cases was used to disable time drifting tests. In other cases replace `__ARM_FM` with `TARGET_ARM_FM` which is more suitable.
1 parent c325dbc commit 86dab2f

File tree

10 files changed

+17
-16
lines changed

10 files changed

+17
-16
lines changed

TESTS/mbed_drivers/lp_timeout/main.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,8 @@ Case cases[] = {
7474
Case("1 s delay during deepsleep (attach_us)", test_deepsleep<AttachUSTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
7575
greentea_failure_handler),
7676
#endif
77-
#if !defined(__ARM_FM) //FastModels not support time drifting test
77+
78+
#if !defined(SKIP_TIME_DRIFT_TESTS)
7879
Case("Timing drift (attach)", test_drift<AttachTester<LowPowerTimeout> >),
7980
Case("Timing drift (attach_us)", test_drift<AttachUSTester<LowPowerTimeout> >),
8081
#endif

TESTS/mbed_drivers/ticker/main.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,8 @@ Case cases[] = {
329329
Case("Test detach", test_detach),
330330
Case("Test multi call and time measure", test_multi_call_time),
331331
Case("Test multi ticker", test_multi_ticker),
332-
#if !defined(__ARM_FM) //FastModels not support time drifting test
332+
333+
#if !defined(SKIP_TIME_DRIFT_TESTS)
333334
Case("Test timers: 1x ticker", test_case_1x_ticker),
334335
Case("Test timers: 2x ticker", test_case_2x_ticker)
335336
#endif

TESTS/mbed_drivers/timeout/main.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,8 @@ Case cases[] = {
6868
Case("1 s delay during sleep (attach_us)", test_sleep<AttachUSTester<Timeout>, 1000000, LONG_DELTA_US>,
6969
greentea_failure_handler),
7070
#endif
71-
#if !defined(__ARM_FM) //FastModels not support time drifting test
71+
72+
#if !defined(SKIP_TIME_DRIFT_TESTS)
7273
Case("Timing drift (attach)", test_drift<AttachTester<Timeout> >),
7374
Case("Timing drift (attach_us)", test_drift<AttachUSTester<Timeout> >),
7475
#endif

TESTS/mbed_hal/common_tickers_freq/main.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,11 @@
3030
#include "hal/lp_ticker_api.h"
3131
#include "hal/mbed_lp_ticker_wrapper.h"
3232

33-
#if !DEVICE_USTICKER
33+
#if defined(SKIP_TIME_DRIFT_TESTS)
3434
#error [NOT_SUPPORTED] test not supported
3535
#endif
3636

37-
//FastModels not support time drifting test
38-
#if defined(__ARM_FM)
37+
#if !DEVICE_USTICKER
3938
#error [NOT_SUPPORTED] test not supported
4039
#endif
4140

TESTS/mbed_platform/wait_ns/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
#include "hal/lp_ticker_api.h"
2525

2626
//FastModels not support timing test
27-
#if defined(__ARM_FM)
27+
#if defined(TARGET_ARM_FM)
2828
#error [NOT_SUPPORTED] test not supported
2929
#endif
3030

TESTS/mbedmicro-rtos-mbed/basic/main.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,15 @@
1919
#include "utest/utest.h"
2020
#include "unity/unity.h"
2121

22-
#if defined(MBED_RTOS_SINGLE_THREAD)
22+
#if defined(SKIP_TIME_DRIFT_TESTS)
2323
#error [NOT_SUPPORTED] test not supported
2424
#endif
2525

26-
#if !DEVICE_USTICKER
26+
#if defined(MBED_RTOS_SINGLE_THREAD)
2727
#error [NOT_SUPPORTED] test not supported
2828
#endif
2929

30-
//FastModels not support time drifting test
31-
#if defined(__ARM_FM)
30+
#if !DEVICE_USTICKER
3231
#error [NOT_SUPPORTED] test not supported
3332
#endif
3433

TESTS/mbedmicro-rtos-mbed/mail/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ using namespace utest::v1;
3131

3232
#if defined(__CORTEX_M23) || defined(__CORTEX_M33)
3333
#define THREAD_STACK_SIZE 512
34-
#elif defined(__ARM_FM)
34+
#elif defined(TARGET_ARM_FM)
3535
#define THREAD_STACK_SIZE 512
3636
#elif defined(TARGET_CY8CKIT_062_WIFI_BT_PSA)
3737
#define THREAD_STACK_SIZE 512

TESTS/mbedmicro-rtos-mbed/malloc/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ volatile bool thread_should_continue = true;
3939
#define THREAD_STACK_SIZE 512
4040
#elif defined(__CORTEX_M23) || defined(__CORTEX_M33)
4141
#define THREAD_STACK_SIZE 512
42-
#elif defined(__ARM_FM)
42+
#elif defined(TARGET_ARM_FM)
4343
#define THREAD_STACK_SIZE 512
4444
#elif defined(TARGET_CY8CKIT_062_WIFI_BT_PSA)
4545
#define THREAD_STACK_SIZE 512

TESTS/mbedmicro-rtos-mbed/threads/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
#define PARALLEL_THREAD_STACK_SIZE 512
3535
#elif defined(__CORTEX_M23) || defined(__CORTEX_M33)
3636
#define PARALLEL_THREAD_STACK_SIZE 512
37-
#elif defined(__ARM_FM)
37+
#elif defined(TARGET_ARM_FM)
3838
#define PARALLEL_THREAD_STACK_SIZE 512
3939
#elif defined(TARGET_CY8CKIT_062_WIFI_BT_PSA)
4040
#define PARALLEL_THREAD_STACK_SIZE 512

targets/targets.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4265,7 +4265,7 @@
42654265
"SERIAL_FC",
42664266
"TRNG",
42674267
"FLASH",
4268-
"QSPI",
4268+
"QSPI",
42694269
"MPU"
42704270
],
42714271
"release_versions": ["2", "5"],
@@ -8030,7 +8030,7 @@
80308030
"ARM_FM": {
80318031
"inherits": ["Target"],
80328032
"public": false,
8033-
"macros": ["__ARM_FM"],
8033+
"macros": ["SKIP_TIME_DRIFT_TESTS"],
80348034
"extra_labels": ["ARM_FM"]
80358035
},
80368036
"FVP_MPS2": {

0 commit comments

Comments
 (0)