[rtems-central commit] spec: Unify test attribute keys
Sebastian Huber
sebh at rtems.org
Thu Aug 20 14:13:13 UTC 2020
Module: rtems-central
Branch: master
Commit: 48d7a6858582560f763a51ed2ddb48fbeb079573
Changeset: http://git.rtems.org/rtems-central/commit/?id=48d7a6858582560f763a51ed2ddb48fbeb079573
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Fri Aug 14 08:57:04 2020 +0200
spec: Unify test attribute keys
---
rtemsspec/tests/spec-validation/tc.yml | 30 +++++++-------
rtemsspec/tests/spec-validation/tc2.yml | 30 +++++++-------
rtemsspec/tests/spec-validation/tc3.yml | 30 +++++++-------
rtemsspec/tests/spec-validation/tc4.yml | 22 +++++------
rtemsspec/tests/spec-validation/ts.yml | 11 ++++--
rtemsspec/validation.py | 54 +++++++++++++-------------
spec/req/rtems/barrier/val/ident.yml | 34 ++++++++--------
spec/req/rtems/message/val/ident.yml | 34 ++++++++--------
spec/req/rtems/part/val/ident.yml | 34 ++++++++--------
spec/req/rtems/ratemon/val/ident.yml | 34 ++++++++--------
spec/req/rtems/sem/val/ident.yml | 34 ++++++++--------
spec/req/rtems/timer/val/ident.yml | 34 ++++++++--------
spec/req/rtems/userext/val/ident.yml | 34 ++++++++--------
spec/spec/test-case.yml | 20 +++++-----
spec/spec/test-suite.yml | 12 +++---
spec/testsuites/validation-0.yml | 20 +++++-----
spec/testsuites/validation/c-library.yml | 30 +++++++-------
spec/testsuites/validation/classic-barrier.yml | 30 +++++++-------
spec/testsuites/validation/profile.yml | 20 +++++-----
19 files changed, 276 insertions(+), 271 deletions(-)
diff --git a/rtemsspec/tests/spec-validation/tc.yml b/rtemsspec/tests/spec-validation/tc.yml
index 682ac54..c6ff486 100644
--- a/rtemsspec/tests/spec-validation/tc.yml
+++ b/rtemsspec/tests/spec-validation/tc.yml
@@ -1,5 +1,9 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-actions:
- action: |
/* Test case action 0 code */
checks:
@@ -32,23 +36,19 @@ actions:
description: |
Test case action 1 description.
links: []
-brief: Test case brief description.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: Test case description.
-enabled-by: true
-epilogue: |
+test-brief: Test case brief description.
+test-description: Test case description.
+test-epilogue: |
/* Test case epilogue code */
-fixture: null
-includes:
+test-fixture: null
+test-header: null
+test-includes:
- a.h
-links: []
-local-includes:
+test-local-includes:
- x.h
-prologue: |
+test-prologue: |
/* Test case prologue code */
-support: |
+test-support: |
/* Test case support code */
-target: tc12.c
-test-header: null
+test-target: tc12.c
type: test-case
diff --git a/rtemsspec/tests/spec-validation/tc2.yml b/rtemsspec/tests/spec-validation/tc2.yml
index 90be0ee..bbf884a 100644
--- a/rtemsspec/tests/spec-validation/tc2.yml
+++ b/rtemsspec/tests/spec-validation/tc2.yml
@@ -1,5 +1,9 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-actions:
- action: |
/* Test case 2 action 0 code */
checks:
@@ -22,20 +26,16 @@ actions:
description: |
Test case 2 action 1 description.
links: []
-brief: Test case 2 brief description.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: Test case 2 description.
-enabled-by: true
-epilogue: null
-fixture: test_case_2_fixture
-includes:
+test-brief: Test case 2 brief description.
+test-description: Test case 2 description.
+test-epilogue: null
+test-fixture: test_case_2_fixture
+test-header: null
+test-includes:
- b.h
-links: []
-local-includes:
+test-local-includes:
- y.h
-prologue: null
-support: null
-target: tc12.c
-test-header: null
+test-prologue: null
+test-support: null
+test-target: tc12.c
type: test-case
diff --git a/rtemsspec/tests/spec-validation/tc3.yml b/rtemsspec/tests/spec-validation/tc3.yml
index e16a932..8a51a18 100644
--- a/rtemsspec/tests/spec-validation/tc3.yml
+++ b/rtemsspec/tests/spec-validation/tc3.yml
@@ -1,5 +1,9 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-actions:
- action: |
/* Test case 3 action 0 code */
checks:
@@ -11,20 +15,16 @@ actions:
description: |
Test case 3 action 0 description.
links: []
-brief: Test case 3 brief description.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: Test case 3 description.
-enabled-by: true
-epilogue: null
-fixture: null
-includes:
+test-brief: Test case 3 brief description.
+test-description: Test case 3 description.
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes:
- c.h
-links: []
-local-includes:
+test-local-includes:
- z.h
-prologue: null
-support: null
-target: tc34.c
-test-header: null
+test-prologue: null
+test-support: null
+test-target: tc34.c
type: test-case
diff --git a/rtemsspec/tests/spec-validation/tc4.yml b/rtemsspec/tests/spec-validation/tc4.yml
index 59ecaf8..c05bfd3 100644
--- a/rtemsspec/tests/spec-validation/tc4.yml
+++ b/rtemsspec/tests/spec-validation/tc4.yml
@@ -1,18 +1,18 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions: []
-brief: Test case 4 brief description.
copyrights:
- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: Test case 4 description.
enabled-by: true
-epilogue: |
- /* Test case 4 epilogue code */
-fixture: null
-includes: []
links: []
-local-includes: []
-prologue: null
-support: null
-target: tc34.c
+test-actions: []
+test-brief: Test case 4 brief description.
+test-description: Test case 4 description.
+test-epilogue: |
+ /* Test case 4 epilogue code */
+test-fixture: null
test-header: null
+test-includes: []
+test-local-includes: []
+test-prologue: null
+test-support: null
+test-target: tc34.c
type: test-case
diff --git a/rtemsspec/tests/spec-validation/ts.yml b/rtemsspec/tests/spec-validation/ts.yml
index 321a472..ee89c4f 100644
--- a/rtemsspec/tests/spec-validation/ts.yml
+++ b/rtemsspec/tests/spec-validation/ts.yml
@@ -5,10 +5,13 @@ copyrights:
- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
description: The Blue Green description.
enabled-by: true
-includes:
-- blue.h
links: []
-local-includes:
+test-code: |
+ /* Blue green code */
+test-description: The Blue Green description.
+test-includes:
+- blue.h
+test-local-includes:
- green.h
-target: ts.c
+test-target: ts.c
type: test-suite
diff --git a/rtemsspec/validation.py b/rtemsspec/validation.py
index 0ababc1..3e55702 100644
--- a/rtemsspec/validation.py
+++ b/rtemsspec/validation.py
@@ -103,12 +103,22 @@ class _TestItem:
@property
def includes(self) -> List[str]:
""" Returns the list of includes. """
- return self._item["includes"]
+ return self._item["test-includes"]
@property
def local_includes(self) -> List[str]:
""" Returns the list of local includes. """
- return self._item["local-includes"]
+ return self._item["test-local-includes"]
+
+ @property
+ def brief(self) -> str:
+ """ Returns the substituted brief description. """
+ return self.substitute_text(self["test-brief"])
+
+ @property
+ def description(self) -> str:
+ """ Returns the substituted description. """
+ return self.substitute_text(self["test-description"])
@property
def group_identifier(self) -> str:
@@ -138,7 +148,7 @@ class _TestItem:
content.add(["@brief Test Case", "", "@{"])
def _add_test_case_action_description(self, content: CContent) -> None:
- actions = self["actions"]
+ actions = self["test-actions"]
if actions:
content.add("This test case performs the following actions:")
for action in actions:
@@ -151,7 +161,7 @@ class _TestItem:
def _generate_test_case_actions(self) -> CContent:
content = CContent()
- for action in self["actions"]:
+ for action in self["test-actions"]:
content.add(self.substitute_code(action["action"]))
for check in action["checks"]:
content.append(self.substitute_text(check["check"]))
@@ -161,27 +171,27 @@ class _TestItem:
test_case_to_suites: Dict[str, List["_TestItem"]]) -> None:
""" Generates the content. """
self.add_test_case_description(content, test_case_to_suites)
- content.add(self.substitute_code(self["support"]))
+ content.add(self.substitute_code(self["test-support"]))
with content.function_block(f"void T_case_body_{self.ident}( void )"):
- content.add_brief_description(self.substitute_text(self["brief"]))
- content.wrap(self.substitute_text(self["description"]))
+ content.add_brief_description(self.brief)
+ content.wrap(self.description)
self._add_test_case_action_description(content)
content.gap = False
params = [f"{self.ident}"]
- fixture = self["fixture"]
+ fixture = self["test-fixture"]
if fixture:
params.append(f"&{fixture}")
name = "T_TEST_CASE_FIXTURE"
else:
name = "T_TEST_CASE"
with content.function("", name, params):
- content.add(self.substitute_code(self["prologue"]))
+ content.add(self.substitute_code(self["test-prologue"]))
self._text_mapper.reset_step()
action_content = self._generate_test_case_actions()
if self._text_mapper.steps > 0:
content.add(f"T_plan({self._text_mapper.steps});")
content.add(action_content)
- content.add(self.substitute_code(self["epilogue"]))
+ content.add(self.substitute_code(self["test-epilogue"]))
content.add("/** @} */")
@@ -195,9 +205,9 @@ class _TestSuiteItem(_TestItem):
_test_case_to_suites: Dict[str, List[_TestItem]]) -> None:
with content.defgroup_block(self.group_identifier, self.name):
content.add(["@ingroup RTEMSTestSuites", "", "@brief Test Suite"])
- content.wrap(self.substitute_text(self["description"]))
+ content.wrap(self.description)
content.add("@{")
- content.add(self.substitute_code(self["code"]))
+ content.add(self.substitute_code(self["test-code"]))
content.add("/** @} */")
@@ -269,14 +279,6 @@ class _TestDirectiveItem(_TestItem):
""" Returns the test case context type. """
return f"{self._ident}_Context"
- @property
- def includes(self) -> List[str]:
- return self._item["test-includes"]
-
- @property
- def local_includes(self) -> List[str]:
- return self._item["test-local-includes"]
-
def _add_pre_condition_descriptions(self, content: CContent) -> None:
for condition in self["pre-conditions"]:
content.add("static const char * const "
@@ -536,8 +538,8 @@ class _TestDirectiveItem(_TestItem):
else:
with content.function_block(
f"void T_case_body_{self.ident}( void )"):
- content.add_brief_description(self["test-brief"])
- content.wrap(self["test-description"])
+ content.add_brief_description(self.brief)
+ content.wrap(self.description)
content.gap = False
ret = ""
name = "T_TEST_CASE_FIXTURE"
@@ -592,8 +594,8 @@ class _TestDirectiveItem(_TestItem):
_directive_add_enum(content, self._post_index_to_enum)
content.add(self.substitute_code(header["code"]))
with content.doxygen_block():
- content.add_brief_description(self["test-brief"])
- content.wrap(self["test-description"])
+ content.add_brief_description(self.brief)
+ content.wrap(self.description)
content.add_param_description(header["run-params"])
content.gap = False
content.declare_function("void", f"{self.ident}_Run",
@@ -745,7 +747,7 @@ def _gather_action(item: Item, source_files: Dict[str, _SourceFile],
def _gather_test_case(item: Item, source_files: Dict[str, _SourceFile],
_test_programs: List[_TestProgram]) -> None:
- src = _get_source_file(item["target"], source_files)
+ src = _get_source_file(item["test-target"], source_files)
src.add_test_case(item)
@@ -756,7 +758,7 @@ def _gather_test_program(item: Item, _source_files: Dict[str, _SourceFile],
def _gather_test_suite(item: Item, source_files: Dict[str, _SourceFile],
_test_programs: List[_TestProgram]) -> None:
- src = _get_source_file(item["target"], source_files)
+ src = _get_source_file(item["test-target"], source_files)
src.add_test_suite(item)
diff --git a/spec/req/rtems/barrier/val/ident.yml b/spec/req/rtems/barrier/val/ident.yml
index 7fc206c..9f19645 100644
--- a/spec/req/rtems/barrier/val/ident.yml
+++ b/spec/req/rtems/barrier/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident-local:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API partition class
objects defined by ${../../ident-local}.
links: []
-brief: Test the ${/if/rtems/barrier/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/barrier/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident-local.h
-prologue: |
+test-prologue: |
rtems_status_code sc;
rtems_id id_local_object;
@@ -34,7 +35,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicBarrierIdentAction(
rtems_name name,
rtems_id *id
@@ -42,6 +43,5 @@ support: |
{
return rtems_barrier_ident( name, id );
}
-target: testsuites/validation/tc-barrier-ident.c
-test-header: null
+test-target: testsuites/validation/tc-barrier-ident.c
type: test-case
diff --git a/spec/req/rtems/message/val/ident.yml b/spec/req/rtems/message/val/ident.yml
index 18565e6..e49f0ac 100644
--- a/spec/req/rtems/message/val/ident.yml
+++ b/spec/req/rtems/message/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API message queue
class objects defined by ${../../ident}.
links: []
-brief: Test the ${/if/rtems/message/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/message/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident.h
-prologue: |
+test-prologue: |
rtems_status_code sc;
rtems_id id_local_object;
@@ -35,7 +36,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicMessageIdentAction(
rtems_name name,
uint32_t node,
@@ -44,6 +45,5 @@ support: |
{
return rtems_message_queue_ident( name, node, id );
}
-target: testsuites/validation/tc-message-ident.c
-test-header: null
+test-target: testsuites/validation/tc-message-ident.c
type: test-case
diff --git a/spec/req/rtems/part/val/ident.yml b/spec/req/rtems/part/val/ident.yml
index 8120b9f..b66ee21 100644
--- a/spec/req/rtems/part/val/ident.yml
+++ b/spec/req/rtems/part/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API partition class
objects defined by ${../../ident}.
links: []
-brief: Test the ${/if/rtems/part/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/part/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident.h
-prologue: |
+test-prologue: |
static long area[32];
rtems_status_code sc;
rtems_id id_local_object;
@@ -37,7 +38,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicPartIdentAction(
rtems_name name,
uint32_t node,
@@ -46,6 +47,5 @@ support: |
{
return rtems_partition_ident( name, node, id );
}
-target: testsuites/validation/tc-part-ident.c
-test-header: null
+test-target: testsuites/validation/tc-part-ident.c
type: test-case
diff --git a/spec/req/rtems/ratemon/val/ident.yml b/spec/req/rtems/ratemon/val/ident.yml
index 9279cea..5f33e73 100644
--- a/spec/req/rtems/ratemon/val/ident.yml
+++ b/spec/req/rtems/ratemon/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident-local:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API rate monotonic
class objects defined by ${../../ident-local}.
links: []
-brief: Test the ${/if/rtems/part/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/part/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident-local.h
-prologue: |
+test-prologue: |
rtems_status_code sc;
rtems_id id_local_object;
@@ -32,7 +33,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicRatemonIdentAction(
rtems_name name,
rtems_id *id
@@ -40,6 +41,5 @@ support: |
{
return rtems_rate_monotonic_ident( name, id );
}
-target: testsuites/validation/tc-ratemon-ident.c
-test-header: null
+test-target: testsuites/validation/tc-ratemon-ident.c
type: test-case
diff --git a/spec/req/rtems/sem/val/ident.yml b/spec/req/rtems/sem/val/ident.yml
index 3d23135..1f63f09 100644
--- a/spec/req/rtems/sem/val/ident.yml
+++ b/spec/req/rtems/sem/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API semaphore class
objects defined by ${../../ident}.
links: []
-brief: Test the ${/if/rtems/sem/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/sem/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident.h
-prologue: |
+test-prologue: |
rtems_status_code sc;
rtems_id id_local_object;
@@ -35,7 +36,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicSemIdentAction(
rtems_name name,
uint32_t node,
@@ -44,6 +45,5 @@ support: |
{
return rtems_semaphore_ident( name, node, id );
}
-target: testsuites/validation/tc-sem-ident.c
-test-header: null
+test-target: testsuites/validation/tc-sem-ident.c
type: test-case
diff --git a/spec/req/rtems/timer/val/ident.yml b/spec/req/rtems/timer/val/ident.yml
index 3d0f479..755f2e1 100644
--- a/spec/req/rtems/timer/val/ident.yml
+++ b/spec/req/rtems/timer/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident-local:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API timer class
objects defined by ${../../ident-local}.
links: []
-brief: Test the ${/if/rtems/timer/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/timer/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident-local.h
-prologue: |
+test-prologue: |
rtems_status_code sc;
rtems_id id_local_object;
@@ -32,7 +33,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicTimerIdentAction(
rtems_name name,
rtems_id *id
@@ -40,6 +41,5 @@ support: |
{
return rtems_timer_ident( name, id );
}
-target: testsuites/validation/tc-timer-ident.c
-test-header: null
+test-target: testsuites/validation/tc-timer-ident.c
type: test-case
diff --git a/spec/req/rtems/userext/val/ident.yml b/spec/req/rtems/userext/val/ident.yml
index 6308714..5bbf714 100644
--- a/spec/req/rtems/userext/val/ident.yml
+++ b/spec/req/rtems/userext/val/ident.yml
@@ -1,5 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links:
+- role: validation
+ uid: ../ident
+test-actions:
- action: |
${../../ident-local:/test-run}(
id_local_object,
@@ -10,20 +16,15 @@ actions:
Run the generic object identification tests for Classic API user extension
class objects defined by ${../../ident-local}.
links: []
-brief: Test the ${/if/rtems/userext/ident:/name} directive.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes: []
-links:
-- role: validation
- uid: ../ident
-local-includes:
+test-brief: Test the ${/if/rtems/userext/ident:/name} directive.
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes: []
+test-local-includes:
- support-object-ident-local.h
-prologue: |
+test-prologue: |
static const rtems_extensions_table table;
rtems_status_code sc;
rtems_id id_local_object;
@@ -34,7 +35,7 @@ prologue: |
&id_local_object
);
T_assert_rsc_success( sc );
-support: |
+test-support: |
static rtems_status_code ClassicUserExtIdentAction(
rtems_name name,
rtems_id *id
@@ -42,6 +43,5 @@ support: |
{
return rtems_extension_ident( name, id );
}
-target: testsuites/validation/tc-userext-ident.c
-test-header: null
+test-target: testsuites/validation/tc-userext-ident.c
type: test-case
diff --git a/spec/spec/test-case.yml b/spec/spec/test-case.yml
index b8862ae..614bb98 100644
--- a/spec/spec/test-case.yml
+++ b/spec/spec/test-case.yml
@@ -14,24 +14,24 @@ spec-example: null
spec-info:
dict:
attributes:
- actions:
+ test-actions:
description: null
spec-type: test-case-action-list
- brief:
+ test-brief:
description: |
It shall be the test case brief description.
spec-type: str
- description:
+ test-description:
description: |
It shall be the test case description.
spec-type: optional-str
- epilogue:
+ test-epilogue:
description: |
If the value is present, then it shall be the test case epilogue
code. The epilogue code is placed in the test case body after the
test case actions.
spec-type: optional-str
- fixture:
+ test-fixture:
description: |
If the value is present, then it shall be a pointer to the test case
fixture. The test case fixture pointer declaration may be provided
@@ -40,27 +40,27 @@ spec-info:
test-header:
description: null
spec-type: test-header
- includes:
+ test-includes:
description: |
It shall be a list of header files included via ``#include <...>``.
spec-type: list-str
- local-includes:
+ test-local-includes:
description: |
It shall be a list of header files included via ``#include "..."``.
spec-type: list-str
- prologue:
+ test-prologue:
description: |
If the value is present, then it shall be the test case prologue
code. The prologue code is placed in the test case body before the
test case actions. A use case is the declaration of local variables
used by the test case actions.
spec-type: optional-str
- support:
+ test-support:
description: |
If the value is present, then it shall be the test case support code.
The support code is placed at file scope before the test case code.
spec-type: optional-str
- target:
+ test-target:
description: |
It shall be the path to the generated target test case source file.
spec-type: str
diff --git a/spec/spec/test-suite.yml b/spec/spec/test-suite.yml
index 35c99ff..e8d7aaa 100644
--- a/spec/spec/test-suite.yml
+++ b/spec/spec/test-suite.yml
@@ -14,28 +14,28 @@ spec-example: null
spec-info:
dict:
attributes:
- brief:
+ test-brief:
description: |
It shall be the test suite brief description.
spec-type: str
- code:
+ test-code:
description: |
It shall be the test suite code. The test suite code is placed at
file scope in the target source file.
spec-type: str
- description:
+ test-description:
description: |
It shall be the test suite description.
spec-type: optional-str
- includes:
+ test-includes:
description: |
It shall be a list of header files included via ``#include <...>``.
spec-type: list-str
- local-includes:
+ test-local-includes:
description: |
It shall be a list of header files included via ``#include "..."``.
spec-type: list-str
- target:
+ test-target:
description: |
It shall be the path to the generated target test suite source file.
spec-type: str
diff --git a/spec/testsuites/validation-0.yml b/spec/testsuites/validation-0.yml
index e6a5d01..6b1e6cb 100644
--- a/spec/testsuites/validation-0.yml
+++ b/spec/testsuites/validation-0.yml
@@ -1,7 +1,11 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-brief: |
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-brief: |
This test suite contains a collection of unrelated test cases.
-code: |
+test-code: |
static char runner_task_stack[ RTEMS_MINIMUM_STACK_SIZE ];
static char buffer[ 512 ];
@@ -106,15 +110,11 @@ code: |
#define CONFIGURE_INIT
#include <rtems/confdefs.h>
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-includes:
+test-description: null
+test-includes:
- rtems.h
- rtems/bspIo.h
- rtems/sysinit.h
-links: []
-local-includes: []
-target: testsuites/validation/ts-validation-0.c
+test-local-includes: []
+test-target: testsuites/validation/ts-validation-0.c
type: test-suite
diff --git a/spec/testsuites/validation/c-library.yml b/spec/testsuites/validation/c-library.yml
index dda4d36..e2abea9 100644
--- a/spec/testsuites/validation/c-library.yml
+++ b/spec/testsuites/validation/c-library.yml
@@ -1,5 +1,9 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-actions:
- action: |
p = aligned_alloc(128, 4);
checks:
@@ -53,26 +57,22 @@ actions:
Set a source integer variable to one, set a destination integer variable to
two, and copy the source to the destination variable through memcpy().
links: []
-brief: |
+test-brief: |
This test case calls functions of the C Library which are included in the
space profile.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: null
-fixture: null
-includes:
+test-description: null
+test-epilogue: null
+test-fixture: null
+test-header: null
+test-includes:
- rtems.h
- stdlib.h
- rtems/malloc.h
-links: []
-local-includes: []
-prologue: |
+test-local-includes: []
+test-prologue: |
void *p;
int s;
int d;
-support: null
-target: testsuites/validation/tc-space-profile.c
-test-header: null
+test-support: null
+test-target: testsuites/validation/tc-space-profile.c
type: test-case
diff --git a/spec/testsuites/validation/classic-barrier.yml b/spec/testsuites/validation/classic-barrier.yml
index d72b49a..0832589 100644
--- a/spec/testsuites/validation/classic-barrier.yml
+++ b/spec/testsuites/validation/classic-barrier.yml
@@ -1,5 +1,9 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-actions:
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-actions:
- action: |
id = 0xffffffff;
sc = rtems_barrier_create(name, RTEMS_BARRIER_AUTOMATIC_RELEASE, 1, &id);
@@ -60,27 +64,23 @@ actions:
description: |
Wait with an infinite timeout for the barrier.
links: []
-brief: |
+test-brief: |
This test case calls functions of the Barrier Manager which are included in
the space profile.
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-epilogue: |
+test-description: null
+test-epilogue: |
T_check_rtems_barriers(T_EVENT_RUN_INITIALIZE_EARLY, T_case_name());
-fixture: null
-includes:
+test-fixture: null
+test-header: null
+test-includes:
- rtems.h
-links: []
-local-includes: []
-prologue: |
+test-local-includes: []
+test-prologue: |
static const rtems_name name = rtems_build_name('B', 'A', 'R', 'R');
rtems_status_code sc;
rtems_id id;
rtems_id id2;
uint32_t released;
-support: null
-target: testsuites/validation/tc-space-profile.c
-test-header: null
+test-support: null
+test-target: testsuites/validation/tc-space-profile.c
type: test-case
diff --git a/spec/testsuites/validation/profile.yml b/spec/testsuites/validation/profile.yml
index b81556d..75f3fef 100644
--- a/spec/testsuites/validation/profile.yml
+++ b/spec/testsuites/validation/profile.yml
@@ -1,8 +1,12 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
-brief: |
+copyrights:
+- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by: true
+links: []
+test-brief: |
This test suite contains test cases which call in combination all functions
included in the space profile.
-code: |
+test-code: |
#define NAME rtems_build_name('N', 'A', 'M', 'E')
static void fatal_extension(
@@ -142,16 +146,12 @@ code: |
#define CONFIGURE_INIT
#include <rtems/confdefs.h>
-copyrights:
-- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
-description: null
-enabled-by: true
-includes:
+test-description: null
+test-includes:
- rtems.h
- rtems/bspIo.h
- rtems/sysinit.h
- rtems/score/sysstate.h
-links: []
-local-includes: []
-target: testsuites/validation/ts-space-profile.c
+test-local-includes: []
+test-target: testsuites/validation/ts-space-profile.c
type: test-suite
More information about the vc
mailing list