Commit Graph

148 Commits (mbed-os-5.13)

Author SHA1 Message Date
int_szyk 6cb405d3b8 tweak watchdog kick reset test Change the value of KICK_ADVANCE_MS so targets pass the test in worst cases 2019-08-23 11:37:41 +01:00
int_szyk ef369dd926 Newline at the end of files 2019-08-12 08:32:07 +01:00
int_szyk 6d38596a27 Updated testcases 2019-08-12 08:32:06 +01:00
Chun-Chieh Li c19397da8d Fix mbed_drivers-watchdog failing with OOM
This is to fix OOM error on targets with just 16KiB RAM.
2019-07-25 15:18:27 +01:00
Filip Jagodzinski a7178b3519 Test: Watchdog: Fix test_restart case
Watchdog::stop() is called in this test. If the target does not support
stopping the watchdog this case needs to be skipped.
Also improve handling ignored test cases.
2019-07-11 11:55:28 +01:00
Filip Jagodzinski fd92a22993 Test: Watchdog: Fix astyle errors 2019-07-11 11:55:28 +01:00
Filip Jagodzinski 9c6cd2b669 Test: Watchdog: Add new driver tests 2019-07-11 11:55:28 +01:00
Filip Jagodzinski df372fd19e ResetReason: Update the header file
Minor doxygen fixes.
2019-07-11 11:55:18 +01:00
Martin Kojtal 2a26e1af4b watchdog: fix copyright 2019-07-11 11:55:18 +01:00
Filip Jagodzinski f52eca9ebe Test: update reset_reason driver test
Update the watchdog timing requirements:
1. The watchdog should trigger at, or after the timeout value.
2. The watchdog should trigger before twice the timeout value.

Use a SERIAL_FLUSH_TIME_MS value consistent with other tests.
2019-07-11 11:55:17 +01:00
Filip Jagodzinski 51835f005b Tests: ResetReason: Use the HAL watchdog API
The Watchdog driver has been updated making this test incompatible
with the new API. Use HAL API instead.
2019-07-11 11:55:16 +01:00
Filip Jagodzinski 5bf6842efc Tests: Watchdog: Remove outdated driver tests
The Watchdog driver has been updated making these tests incompatible
with the new API. The Watchdog driver functionality is tested with the
unit tests located in UNITTESTS/drivers/Watchdog/ .
2019-07-11 11:55:16 +01:00
Filip Jagodzinski f5e61b99a1 Docs: Watchdog: Update code comments
* capitalize driver class name,
* reword test docs for the driver & HAL,
* capitalize Mbed name,
* reword the comments explaining the SERIAL_FLUSH_TIME_MS macro.
2019-07-11 11:55:11 +01:00
Amanda Butler c04ba485fc Edit ResetReason_tests.h
Make minor grammar edits.
2019-07-11 11:55:10 +01:00
Donatien Garnier ec010fc5e6 Fix more astyle failures 2019-07-11 11:55:10 +01:00
Donatien Garnier fd7e46b799 Apply new astyle config style 2019-07-11 11:55:09 +01:00
Donatien Garnier 7c05a83afa Update license headers 2019-07-11 11:55:09 +01:00
Steve Cartmell 4f2acf5f03 test(api-watchdog): Fix errors in compiling watchdog greentea tests
The latest rebase of the watchdog feature branch introduced errors in compiling
watchdog tests due to missing headers.

- Watchdog HAL API test
  Include missing header files to main.cpp (mbed_wait_api.h, stdlib.h).

- Watchdog HAL API timing test
  Include missing header files to main.cpp (us_ticker_api.h).

- Watchdog Driver API test
  Include missing header files to main.cpp (mbed_wait_api.h, stdlib.h).
  Inject mbed namespace into main.cpp to fix Watchdog name resolution.
2019-07-11 11:55:09 +01:00
Filip Jagodzinski 008cd6453c Tests: Drivers: Reset_reason: Add tests 2019-07-11 11:55:06 +01:00
Filip Jagodzinski 91c9cb5c0f Tests: Drivers: Watchdog: Add tests 2019-07-11 11:55:05 +01:00
Neil Tuttle 7205238c3b Fix error in tests-mbed_drivers-ticker when LED not available 2019-07-11 11:41:30 +01:00
d-kato 099617dfd9 tests-mbed_drivers-crc: Increase the task stack 2019-07-11 11:40:52 +01:00
Przemyslaw Stekiel aba5ca72cd tests-mbed_drivers-lp_timeout: Rework "Zero delay" test case
Execute test case 100 times in loop since one run is not enough to catch possible failure.
2019-07-11 11:40:52 +01:00
Przemyslaw Stekiel 1a2af2c7b6 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.
2019-07-11 11:40:51 +01:00
Przemyslaw Stekiel 1ddebcd9b7 Fix GREENTEA_SETUP() call in not time drifting tests.
In these tests GREENTEA_SETUP() is incorrectly called with "timing_drift_auto" instead of "default_auto".
2019-07-11 11:40:51 +01:00
Laurent Meunier 46860d14dd timeout_tests: do not call sleep from test thread
This is up to scheduler to call sleep when threads are inactive.
So the thread should simply wait for the semaphore for ever (or test timeout).
2019-07-11 11:39:48 +01:00
Kevin Bracey 2fbbd9d2ca Introduce Semaphore::acquire methods
Deprecate wait() in favour of acquire(), try_acquire(),
try_acquire_for() and try_acquire_until().

Brings Semaphore more into line with CMSIS-RTOS 2 (which uses "acquire"),
itself (as it has "release"), and other classes having "try", "try for"
and "try until".

Also steps away from vague "wait" term - the primary operation here is
to acquire the semaphore, and this will of course sleep.
2019-05-28 17:02:06 +03:00
Qinghao Shi 2603e295e8 FastModel: Skip low-power ticker time drifting test for models
FastModels are a software simulator for Arm platform/cores.
They mean to be used as a tool for testing or early prototype stage development.
Due to the nature of software simulator can't grantee the timing accuracy like HW.
So time drifting test is skipped for software models.
2019-04-03 16:51:02 +01:00
Amir Cohen 92ed1cb10c Add flash sum check
Check that flash size sum up to all sectors combined
2019-02-14 17:30:51 +02:00
jeromecoutant b712e71194 FLASHIAP test: skip test if test region overlaps code 2019-01-04 16:38:32 +01:00
David Saada f3bac3451c Fix FLASHIAP_ROM_END macro for GCC_ARM & IAR toolchains
- Consider data section in GCC_ARM toolchain
- Consider init_array section in IAR toolchain
- Rename macro to FLASHIAP_APP_ROM_END_ADDR for clarity sake
2018-12-19 12:05:08 +02:00
David Saada 542744d03c Support erase value in Flash HAL drivers, FlashIAP and block devices 2018-11-07 14:23:07 +02:00
kegilbert a2ac895c37 This reverts commit 9b53d1256fb358407acbaf81c70b71d937b1f7cd.i
Move the memory tracing enabled macro to a config option but
revert the !defined -> #if changes to no longer cause breaking
changes.
2018-10-26 17:35:33 -05:00
Martin Kojtal bbfa322afb tests: fix astyle 2018-10-25 09:58:17 +01:00
Kevin Bracey 1ef213ec89 Clean up Thread deprecation warnings
Static Thread methods and signal methods have been deprecated. Remove
all references in the main code, and most of the tests. Some tests of
the deprecated APIs themselves remain.
2018-10-12 14:57:13 +03:00
Cruz Monrreal 1e3e69463f
Merge pull request #7781 from deepikabhavnani/crc_safety
Add thread safety to CRC class
2018-08-29 15:42:23 -05:00
Cruz Monrreal 1b051c7687
Merge pull request #7402 from kegilbert/mem-tracing-config-patch
Replace mbed_mem_tracing_enabled macro with config option
2018-08-27 10:34:24 -05:00
Martin Kojtal a24cecfc94
Merge pull request #7805 from jamesbeyond/fm_test
Skip Greentea tests for Mbed OS code coverage on Fast Models
2018-08-27 10:39:43 +02:00
Qinghao Shi c9ac4868ac move test skipping macro for FastModels to top of the test 2018-08-23 22:30:55 +01:00
Qinghao Shi 0ad1934f32 move test skipping macro to case array section 2018-08-22 17:48:03 +01:00
deepikabhavnani 986411ccb0 Add thread safety to CRC class
Thread safety is added to serialize the hardware CRC and will not
impact the software CRC.
2018-08-21 15:26:05 -05:00
Cruz Monrreal e02466a77a
Merge pull request #7524 from c1728p9/tickless_fix
Fixes for tickless and LPTICKER_DELAY_TICKS
2018-08-21 10:03:41 -05:00
Qinghao Shi 891c4ed244 Skip time drifting test on FastModels targets
FastModels targets are simulator running on the x86 hosts.
As the nature of non-RealTime x86 OS and FastModels, timing accuracy is not guaranteed
So skipping the time drifting tests on FastModel targets
2018-08-17 17:46:28 +01:00
Russ Butler 472ababfef Update deep sleep lock check in tests
When the define LPTICKER_DELAY_TICKS is set deep sleep can be randomly
disallowed when using the low power ticker. This is because a Timer
object, which locks deep sleep, is used to protect from back-to-back
writes to lp tickers which can't support that. This causes tests which
assert that deep sleep is allowed to intermittently fail.

To fix this intermittent failure this patch adds the function
sleep_manager_can_deep_sleep_test_check() which checks if deep sleep
is allowed over a duration. It updates all the tests to use
sleep_manager_can_deep_sleep_test_check() rather
than sleep_manager_can_deep_sleep() so the tests work even if deep
sleep is spuriously blocked.
2018-08-17 09:29:41 -05:00
David Saada 876b5f755b FlashIAP & NVStore tests: Skip test if overwriting code in flash. 2018-08-16 21:59:45 +03:00
Nir Sonnenschein 2b8eb5ec0e
Merge pull request #7752 from maciejbocianski/timer_test_fix
tests-mbed_drivers-timer: change delay method
2018-08-14 19:42:43 +03:00
Maciej Bocianski efe9e44208 tests-mbed_drivers-timer: change delay method 2018-08-10 09:52:07 +02:00
jeromecoutant f532159b61 Timeout tests : unstable result
RTX waits, such as sem.wait(N), delays for between N-1 and N cycles.
As lp_ticker is not so accurate as us_ticker,
sometines, wait is expiring just before the lp_timeout.
2018-08-09 10:13:17 +02:00
kegilbert 9b53d1256f Replace mbed_mem_tracing_enabled macro with config option 2018-08-06 13:44:12 -05:00
Martin Kojtal e52bb68f93 tests: astyle fix
All tests should comply to our coding standard now
2018-08-03 10:23:38 +01:00