1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
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/ident
test-actions:
- action-brief: |
Run the generic object identification tests for Classic API message queue
class objects defined by ${../../req/ident}.
action-code: |
rtems_status_code sc;
rtems_id id_local_object;
sc = rtems_message_queue_construct(
&ClassicObjectIdentConfig,
&id_local_object
);
T_assert_rsc_success( sc );
${../../req/ident:/test-run}(
id_local_object,
NAME_LOCAL_OBJECT,
ClassicMessageIdentAction
);
sc = rtems_message_queue_delete( id_local_object );
T_rsc_success( sc );
checks: []
links: []
test-brief: Test the ${../if/ident:/name} directive.
test-context: []
test-context-support: null
test-description: null
test-header: null
test-includes: []
test-local-includes:
- tr-object-ident.h
test-setup: null
test-stop: null
test-support: |
#define NAME_LOCAL_OBJECT rtems_build_name( 'M', 'E', 'S', 'Q' )
static RTEMS_MESSAGE_QUEUE_BUFFER( 1 ) ClassicMessageIdentBuffers[ 1 ];
static rtems_message_queue_config ClassicObjectIdentConfig = {
.name = NAME_LOCAL_OBJECT,
.maximum_pending_messages = RTEMS_ARRAY_SIZE( ClassicMessageIdentBuffers ),
.maximum_message_size = 1,
.storage_area = ClassicMessageIdentBuffers,
.storage_size = sizeof( ClassicMessageIdentBuffers ),
.attributes = RTEMS_DEFAULT_ATTRIBUTES
};
static rtems_status_code ClassicMessageIdentAction(
rtems_name name,
uint32_t node,
rtems_id *id
)
{
return rtems_message_queue_ident( name, node, id );
}
test-target: testsuites/validation/tc-message-ident.c
test-teardown: null
type: test-case
|