Commit Graph

105 Commits (73d1c8df93c67ea9e16f5bf1a188eb449a983693)

Author SHA1 Message Date
YarivCol f403623ba5 Add test for empty, full functions in queue and mail 2017-10-05 07:00:18 -07:00
Przemyslaw Stekiel 4509165d61 Add test for Timer class. 2017-10-03 11:54:58 +02:00
Filip Jagodzinski 311d38b925 Tests: RTOS: RtosTimer: Fix tests on debug profile
Redefine error() as noop to fix tests being aborted when compiled
with -DMBED_TRAP_ERRORS_ENABLED=1.
2017-09-26 13:41:18 +02:00
Martin Kojtal 1fed1d003e Merge pull request #4684 from deepikabhavnani/thread_stack_issue
Add thread terminate hook
2017-09-22 11:31:39 +01:00
Deepika 6f5df1f4c3 Threads test require more time to finish 2017-09-15 11:39:47 -05:00
Russ Butler 47b0f31d32 Remove direct use of us and lp ticker from tests
Remove the direct use of the microsecond and low power ticker from
the tests. This enforces that sleep mode is properly locked when
using timers. Furthermore, this prepares the codebase for new ticker
changes which allow differing clock frequencies and timer bit widths.
2017-09-13 20:11:39 -05:00
Jimmy Brisson 81437732dd Merge pull request #4945 from maciejbocianski/mail_tests
Extends test set for Mail class
2017-09-05 11:16:27 -05:00
Filip Jagodzinski 33e38cc0d2 Tests: RTOS: RtosTimer: Add tests 2017-09-04 16:10:54 +02:00
Maciej Bocianski ae0b90f440 Extends test set for Mail class 2017-08-31 15:04:36 +02:00
Bartek Szatkowski b0ad73ea41 RTOS: Changes to the EvenFlags API, doxy and tests 2017-08-15 13:33:32 +01:00
YarivCol dfbcbddd9a RTOS: add tests for EvenFlags class 2017-08-15 13:27:30 +01:00
Christopher Haster 4cad764162 Added copyright header to all tests 2017-08-07 12:02:33 -05:00
Jimmy Brisson a81783e177 Merge pull request #4752 from bulislaw/queue_tests
RTOS: Queue tests & docs rework
2017-08-07 10:27:11 -05:00
Jimmy Brisson c5c470e22c Merge pull request #4729 from bulislaw/mutex_tests
RTOS: Mutex: Rework tests
2017-07-27 09:40:26 -05:00
Jimmy Brisson 160940b30e Merge pull request #4682 from bulislaw/sem_tests
Test: RTOS: Semaphore: Rework tests
2017-07-17 11:06:48 -05:00
Jimmy Brisson 18bb6fdc1f Merge pull request #4620 from bulislaw/thread_tests
Extend tests for RTOS Thread class
2017-07-17 11:03:34 -05:00
Bartek Szatkowski fccfa7e2c0 Tests: RTOS: Queue: Rework and extend tests 2017-07-12 15:39:54 +01:00
Bartek Szatkowski 01c0cfd4f8 RTOS: Mutex: Rework tests
Add descriptions, fix small issues and timings.
2017-07-12 11:02:12 +01:00
Bartek Szatkowski 739a429820 Test: RTOS: Semaphore: Rework tests 2017-07-11 15:01:39 +01:00
Shrikant Tudavekar 8a4dbff8d6 validate base_time key received
This is required as greentea can send multiple __sync packets and cause the
to be in unexpected state.
2017-07-05 12:37:41 -05:00
Bartek Szatkowski 60e7ef2ab7 RTOS: Thread: Rework and extend test suite 2017-06-29 13:04:13 +01:00
Shrikant Tudavekar 73907259d9 Increased stack to 1024 from 768 and corrected assert.
1) mbed-os-tests-mbedmicro-rtos-mbed-basic tests use to fail when run in loop
after 20-25, This was because the stack used by test application was in range of
744-840 bytes. So bumped the stack size to 1024 bytes.

2) Corrected the assert and taken out the assert which was not required.
2017-06-22 18:25:39 -05:00
studavekar 12fe3415bc Deprecate testcases related to time drift.
1) RtosTimer is been Deprecated by EventQueue.
2) wait_us testing can't be reliably tested.
2017-06-22 18:25:38 -05:00
studavekar 0f55193df8 Update timing tests to be robust.
In the new approach the host controls the device activity when the test
should start, finish and pass/fail status is send to device. Also deprecate
the test cases which can't accurately test.
2017-06-22 18:25:16 -05:00
Bartek Szatkowski b793a3fb89 Update codebase for CMSIS5/RTX5
Update all of mbed-os to use RTX5.
2017-05-30 18:55:52 +01:00
Bartek Szatkowski 07fc7aeb89 Remove deprecated Thread constructor usage 2017-05-16 10:54:30 +01:00
Bartek Szatkowski 6a0fcd3c58 Reduce test overhead in preparation for CMSIS 5
Reduce RAM consumption so all tests can still be built when using
CMSIS/RTX5. Also reduce clutter by removing the per target stack size
defines in the tests.
2017-05-14 19:25:19 -05:00
Bartek Szatkowski 9377fa97c9 Rework RTOS mutex tests 2017-02-16 14:07:26 +00:00
Bartek Szatkowski ed41ebef9b Fix deprecated Thread ctor usage in RTOS tests
Thread spawning constructors are deprecated, start function should be
used instead.
2016-12-23 13:16:11 +00:00
Brian Daniels 3880e3a39d Limiting the thread stack for parallel threads test
Previously, the RTOS threads test was conditionally change the thread
stack size for all test cases based on the target. Now, it uses the
default stack size for all targets when threads are created serially,
and uses a 512 byte stack for the threads that are created in parallel.
2016-12-20 17:14:04 -06:00
Russ Butler 92d11df19d Increase stack size in malloc test for Cortex-A
Increase the stack size used in the malloc test to prevent stack
overflows on Cortex-A devices.
2016-12-03 14:21:17 -06:00
Steven Cooreman b64fa3ae18 [EFR32] Reduce test stack sizes on EFR32 2016-11-08 18:33:42 +01:00
Rob Meades 4e808139d3 Add u-blox Sara-N target. 2016-10-15 12:06:29 +01:00
Mike Fiore 1b4a1b11e1 fix RTOS unit tests for MultiTech xDot platform - increase stack sizes in tests 2016-10-03 12:41:52 -05:00
Sam Grove 48ac4aec25 Merge pull request #2830 from jeromecoutant/PR_L073RZ
[STM32L073RZ] update OS5 RTOS tests
2016-09-28 15:00:27 -07:00
Sam Grove ab3e77f50a Merge pull request #2826 from jeromecoutant/PR_F410RB_THREAD
[STM32F410RB] update OS5 RTOS thread test
2016-09-28 14:59:29 -07:00
Sam Grove 28a4b3e03a Merge pull request #2781 from jeromecoutant/PR_RTOS_Tests_clean
Clean RTOS tests after PR #2648
2016-09-28 14:58:43 -07:00
jeromecoutant 1d6d554717 Clean RTOS OS5 tests 2016-09-27 17:26:03 +02:00
jeromecoutant 17c1d97f01 [STM32L073RZ] update OS5 RTOS tests 2016-09-27 16:58:23 +02:00
jeromecoutant 2db0938d67 [STM32F410RB] update OS5 RTOS thread test 2016-09-27 15:04:27 +02:00
jeromecoutant 52f70b06d0 [STM32F091RC] patch for tests-mbedmicro-rtos-mbed-threads 2016-09-27 10:59:34 +02:00
jeromecoutant c416a1286d [NUCLEO_F103RB] RTOS tests update
As this target has 20K RAM, default stack size needs to be tuned
2016-09-22 14:48:11 +02:00
jeromecoutant dc8957a046 STM32F070RB/STM32F072RB: issue with some mbedmicro-rtos-mbed tests
Status is now OK
2016-09-19 10:17:56 +02:00
Russ Butler abbd71da9b Add test case for thread self termination
Test that thread self termination works.
2016-09-07 17:33:33 -05:00
Brian Daniels e678325730 Modifying timing tests to use timing drift host test 2016-08-30 14:53:18 -05:00
Russ Butler 13c06850a2 Add a test for thread-safe malloc
Add a test to repeatedly malloc and free from different threads to
test if these functions are thread safe.
2016-07-29 20:14:07 -05:00
Vincent Coubard a7d1bf7364 Update thread stack size for NRF based targets in rtos tests. 2016-07-28 21:21:31 +01:00
Sam Grove c24e461be3 Merge pull request #2248 from pan-/define_stack_stize_for_RTOS_threads_test
Define stack size of the threads spawned by RTOS threads test.
2016-07-26 20:14:51 -05:00
Vincent Coubard 2099da6d58 Define stack size of the threads spawned by this test.
This stack size is adjusted for NRF51 and NRF52 based targets.
2016-07-25 23:56:14 +01:00
Vincent Coubard 5676cccc7c Define stack size for NRF52. 2016-07-25 23:46:35 +01:00
Sam Grove 0675a58009 Merge pull request #2241 from pan-/fix_stack_definitions
Bring missing stack definitions for various targets.
2016-07-25 14:02:42 -05:00
Vincent Coubard 1752f23ff8 Remove double #else statement 2016-07-25 13:24:57 +01:00
Vincent Coubard d2e683cc1e Bring missing stack definitions for various targets.
Those definitions where available in libraries/test/rtos/mbed/* tests but
not in TESTS/mbedmicro-rtos-mbed/* tests.
2016-07-25 11:57:26 +01:00
Vincent Coubard 80ead8ca1a Fix behavior when mbed-os RTOS tests are build while the system is single
threaded.

For mbed micro, if the MBED_RTOS_SINGLE_THREAD is defined then the
compilation of the test will fail with the info
	[NOT_SUPPORTED] test not supported

This patch bring this behavior to mbed-os RTOS tests.
2016-07-25 11:41:00 +01:00
Brian Daniels a9eb39dee4 Adding test frameworks and test sources
This commit adds the following test frameworks:

- `greentea-client` (https://github.com/ARMmbed/greentea-client)
  - This framework provides a key-value api for communicating with the
    greentea test tool (https://github.com/ARMmbed/greentea)
- `unity` (https://github.com/ARMmbed/unity)
  - This framework provides test assert macros that can be used when
    writing test cases
- `utest` (https://github.com/ARMmbed/utest)
  - This framework allows you to execute a series of test cases with
    reporting that works with the greentea test tool
    (https://github.com/ARMmbed/greentea)

The following changes were made when bringing these frameworks into the
tree:

- References to `mbed_drivers/mbed.h` within utest's tests were migrated
  to `mbed.h`
- The yotta file `module.json` was removed from `greentea-client` and
  `unity`
  - `coverage.json` was also removed from `greentea-client`
- `.gitignore` and `.gitattributes` were removed from `greentea-client`
- Apache 2.0 license files were removed from `greentea-client`

This also brings in a number of tests that have been newly written or ported from various sources:

- `TESTS/integration` - Very basic tests, used to check if testing frameworks are working correctly
- `TESTS/mbed_drivers` (Thanks @PrzemekWirkus!) - TESTS ported from mbed OS 3.0 (https://github.com/ARMmbed/mbed-drivers)
- `TESTS/mbedmicro-mbed` (Thanks @PrzemekWirkus!) - Tests that weren't covered by `TESTS/mbed_drivers` that currently live in `libraries/tests/mbed`
- `TESTS/mbedmicro-rtos-mbed` (Thanks @PrzemekWirkus!) - Ported tests that currently live in `libraries/tests/rtos/mbed`
- `TESTS/storage_abstraction` (Thanks @rgrover!) - Tests for the storage_abstraction hal
2016-07-20 12:41:26 -05:00