diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-09-16 11:48:29 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-09-16 16:33:00 +0200 |
commit | 3bdf817950eadd75a2785b62220eb0b04533b9fd (patch) | |
tree | ed221c6de813e7a473e2882af6326bf2e5b44bd1 /spec/rtems/event/val/system-send-receive.yml | |
parent | spec: Specify rtems_task_construct() (diff) | |
download | rtems-central-3bdf817950eadd75a2785b62220eb0b04533b9fd.tar.bz2 |
spec: Group items by component
Diffstat (limited to 'spec/rtems/event/val/system-send-receive.yml')
-rw-r--r-- | spec/rtems/event/val/system-send-receive.yml | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/spec/rtems/event/val/system-send-receive.yml b/spec/rtems/event/val/system-send-receive.yml new file mode 100644 index 00000000..18bdeb03 --- /dev/null +++ b/spec/rtems/event/val/system-send-receive.yml @@ -0,0 +1,71 @@ +SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause +copyrights: +- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de) +enabled-by: true +links: +- role: validation + uid: ../req/system-receive +- role: validation + uid: ../req/system-send +test-actions: +- action: | + ${../req/send-receive:/test-run}( + EventSystemSend, + EventSystemReceive, + GetPendingSystemEvents, + THREAD_WAIT_CLASS_SYSTEM_EVENT, + STATES_WAITING_FOR_SYSTEM_EVENT + ); + checks: [] + description: | + Run the event send and receive tests for the system event set defined + by ${../req/send-receive}. + links: [] +test-brief: | + Tests the ${../if/system-send:/name} and ${../if/system-receive:/name} + directives. +test-description: null +test-epilogue: null +test-fixture: null +test-header: null +test-includes: +- rtems/rtems/eventimpl.h +- rtems/rtems/tasksdata.h +- rtems/score/statesimpl.h +- rtems/score/threadimpl.h +test-local-includes: +- tr-event-send-receive.h +test-prologue: null +test-support: | + static rtems_status_code EventSystemSend( + rtems_id id, + rtems_event_set event_in + ) + { + return rtems_event_system_send( id, event_in ); + } + + static rtems_status_code EventSystemReceive( + rtems_id event_in, + rtems_option option_set, + rtems_interval ticks, + rtems_event_set *event_out + ) + { + return rtems_event_system_receive( + event_in, + option_set, + ticks, + event_out + ); + } + + static rtems_event_set GetPendingSystemEvents( Thread_Control *thread ) + { + RTEMS_API_Control *api; + + api = thread->API_Extensions[ THREAD_API_RTEMS ]; + return api->System_event.pending_events; + } +test-target: testsuites/validation/tc-event-send-receive.c +type: test-case |