summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-11-11 13:17:46 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-11-13 11:08:43 +0100
commit060008e5fbe3a631f258de0b14441a4a03ec9b62 (patch)
treedb9fbe9e7878372ea3fce2c7afb248740bc05031
parentspecdoc/specverify: Support values of any type (diff)
downloadrtems-central-060008e5fbe3a631f258de0b14441a4a03ec9b62.tar.bz2
spec: Add runtime measurement test case item type
-rw-r--r--spec/spec/requirement-action-condition.yml4
-rw-r--r--spec/spec/requirement-action-state.yml2
-rw-r--r--spec/spec/requirement-action.yml8
-rw-r--r--spec/spec/runtime-measurement-params.yml27
-rw-r--r--spec/spec/runtime-measurement-test.yml87
-rw-r--r--spec/spec/test-context-list.yml (renamed from spec/spec/requirement-action-test-context-list.yml)6
-rw-r--r--spec/spec/test-context.yml (renamed from spec/spec/requirement-action-test-context.yml)4
-rw-r--r--spec/spec/test-run-param.yml2
-rw-r--r--spec/spec/test-support-method.yml (renamed from spec/spec/requirement-action-test-fixture.yml)14
9 files changed, 134 insertions, 20 deletions
diff --git a/spec/spec/requirement-action-condition.yml b/spec/spec/requirement-action-condition.yml
index 36fc34cb..46a31a30 100644
--- a/spec/spec/requirement-action-condition.yml
+++ b/spec/spec/requirement-action-condition.yml
@@ -22,7 +22,7 @@ spec-info:
The epilogue code is placed in the test condition preparation or
check before the state-specific code. The code may use a local
variable ``ctx`` which points to the test context, see
- ${requirement-action-test-context:/spec-name}.
+ ${test-context:/spec-name}.
spec-type: optional-str
test-prologue:
description: |
@@ -30,7 +30,7 @@ spec-info:
The prologue code is placed in the test condition preparation or
check after the state-specific code. The code may use a local
variable ``ctx`` which points to the test context, see
- ${requirement-action-test-context:/spec-name}.
+ ${test-context:/spec-name}.
spec-type: optional-str
description: |
This set of attributes defines an action pre-condition or post-condition.
diff --git a/spec/spec/requirement-action-state.yml b/spec/spec/requirement-action-state.yml
index 8b1e55ba..374f0199 100644
--- a/spec/spec/requirement-action-state.yml
+++ b/spec/spec/requirement-action-state.yml
@@ -17,7 +17,7 @@ spec-info:
description: |
It shall be the test code to prepare or check the state of the
condition. The code may use a local variable ``ctx`` which points to
- the test context, see ${requirement-action-test-context:/spec-name}.
+ the test context, see ${test-context:/spec-name}.
spec-type: str
text:
description: |
diff --git a/spec/spec/requirement-action.yml b/spec/spec/requirement-action.yml
index e588a73b..0e5a4eb1 100644
--- a/spec/spec/requirement-action.yml
+++ b/spec/spec/requirement-action.yml
@@ -160,7 +160,7 @@ spec-info:
spec-type: optional-str
test-context:
description: null
- spec-type: requirement-action-test-context-list
+ spec-type: test-context-list
test-context-support:
description: |
If the value is present, then it shall be the test context support
@@ -190,10 +190,10 @@ spec-info:
spec-type: optional-str
test-setup:
description: null
- spec-type: requirement-action-test-fixture
+ spec-type: test-support-method
test-stop:
description: null
- spec-type: requirement-action-test-fixture
+ spec-type: test-support-method
test-support:
description: |
If the value is present, then it shall be the test case support code.
@@ -205,7 +205,7 @@ spec-info:
spec-type: str
test-teardown:
description: null
- spec-type: requirement-action-test-fixture
+ spec-type: test-support-method
transition-map:
description: null
spec-type: requirement-action-transition-list
diff --git a/spec/spec/runtime-measurement-params.yml b/spec/spec/runtime-measurement-params.yml
new file mode 100644
index 00000000..4e70892b
--- /dev/null
+++ b/spec/spec/runtime-measurement-params.yml
@@ -0,0 +1,27 @@
+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: spec-member
+ uid: root
+spec-description: null
+spec-example: null
+spec-info:
+ dict:
+ attributes:
+ sample-count:
+ description: |
+ It shall be the sample count of the runtime measurement context.
+ spec-type: int
+ description: |
+ This set of attributes defines parameters of the runtime measurement test
+ case.
+ generic-attributes:
+ description: null
+ key-spec-type: name
+ value-spec-type: any
+ mandatory-attributes: all
+spec-name: Runtime Measurement Parameter Set
+spec-type: runtime-measurement-params
+type: spec
diff --git a/spec/spec/runtime-measurement-test.yml b/spec/spec/runtime-measurement-test.yml
new file mode 100644
index 00000000..bc7e8ec9
--- /dev/null
+++ b/spec/spec/runtime-measurement-test.yml
@@ -0,0 +1,87 @@
+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: spec-member
+ uid: root
+- role: spec-refinement
+ spec-key: type
+ spec-value: runtime-measurement-test
+ uid: root
+spec-description: null
+spec-example: null
+spec-info:
+ dict:
+ attributes:
+ params:
+ description: null
+ spec-type: runtime-measurement-params
+ test-brief:
+ description: |
+ If the value is present, then it shall be the test case brief
+ description.
+ spec-type: optional-str
+ test-cleanup:
+ description: |
+ If the value is present, then it shall be the measure runtime request
+ cleanup method. The method is called after each measure runtime
+ request.
+ spec-type: test-support-method
+ test-context:
+ description: null
+ spec-type: test-context-list
+ test-context-support:
+ description: |
+ If the value is present, then it shall be the test context support
+ code. The context support code is placed at file scope before the
+ test context definition.
+ spec-type: optional-str
+ test-description:
+ description: |
+ If the value is present, then it shall be the test case description.
+ spec-type: optional-str
+ test-includes:
+ description: |
+ It shall be a list of header files included via ``#include <...>``.
+ spec-type: list-str
+ test-local-includes:
+ description: |
+ It shall be a list of header files included via ``#include "..."``.
+ spec-type: list-str
+ test-prepare:
+ description: |
+ If the value is present, then it shall be the measure runtime request
+ prepare method. The method is called before each measure runtime
+ request.
+ spec-type: test-support-method
+ test-setup:
+ description: |
+ If the value is present, then it shall be the test case setup fixture
+ method.
+ spec-type: test-support-method
+ test-stop:
+ description: |
+ If the value is present, then it shall be the test case stop fixture
+ method.
+ spec-type: test-support-method
+ 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
+ test-target:
+ description: |
+ It shall be the path to the generated test case source file.
+ spec-type: str
+ test-teardown:
+ description: |
+ If the value is present, then it shall be the test case teardown
+ fixture method.
+ spec-type: test-support-method
+ description: |
+ This set of attributes specifies a runtime measurement test case.
+ mandatory-attributes: all
+spec-name: Runtime Measurement Test Item Type
+spec-type: runtime-measurement-test
+type: spec
diff --git a/spec/spec/requirement-action-test-context-list.yml b/spec/spec/test-context-list.yml
index ae9e0866..a0e6f38c 100644
--- a/spec/spec/requirement-action-test-context-list.yml
+++ b/spec/spec/test-context-list.yml
@@ -10,7 +10,7 @@ spec-example: null
spec-info:
list:
description: null
- spec-type: requirement-action-test-context
-spec-name: Action Requirement Test Context List
-spec-type: requirement-action-test-context-list
+ spec-type: test-context
+spec-name: Test Context List
+spec-type: test-context-list
type: spec
diff --git a/spec/spec/requirement-action-test-context.yml b/spec/spec/test-context.yml
index b5ef3838..fddd78c1 100644
--- a/spec/spec/requirement-action-test-context.yml
+++ b/spec/spec/test-context.yml
@@ -27,6 +27,6 @@ spec-info:
This set of attributes defines an action requirement test context member.
mandatory-attributes: all
none: null
-spec-name: Action Requirement Test Context Member
-spec-type: requirement-action-test-context
+spec-name: Test Context Member
+spec-type: test-context
type: spec
diff --git a/spec/spec/test-run-param.yml b/spec/spec/test-run-param.yml
index 77c0d3c6..fcad7f55 100644
--- a/spec/spec/test-run-param.yml
+++ b/spec/spec/test-run-param.yml
@@ -31,7 +31,7 @@ spec-info:
This set of attributes specifies a parameter for the test run function.
In case this parameter is used in an ${requirement-action:/spec-name}
item, then the parameter is also added as a member to the test context,
- see ${requirement-action-test-context:/spec-name}.
+ see ${test-context:/spec-name}.
mandatory-attributes: all
spec-name: Test Run Parameter
spec-type: test-run-param
diff --git a/spec/spec/requirement-action-test-fixture.yml b/spec/spec/test-support-method.yml
index 15b7c5dc..bce96514 100644
--- a/spec/spec/requirement-action-test-fixture.yml
+++ b/spec/spec/test-support-method.yml
@@ -12,22 +12,22 @@ spec-info:
attributes:
brief:
description: |
- It shall be the test fixture method brief description.
+ It shall be the test support method brief description.
spec-type: optional-str
code:
description: |
- It shall be the test fixture method code. The code may use a local
+ It shall be the test support method code. The code may use a local
variable ``ctx`` which points to the test context, see
- ${requirement-action-test-context:/spec-name}.
+ ${test-context:/spec-name}.
spec-type: str
description:
description: |
- It shall be the test fixture method description.
+ It shall be the test support method description.
spec-type: optional-str
description: |
- This set of attributes defines an action requirement test fixture method.
+ This set of attributes defines an action requirement test support method.
mandatory-attributes: all
none: null
-spec-name: Action Requirement Test Fixture Method
-spec-type: requirement-action-test-fixture
+spec-name: Test Support Method
+spec-type: test-support-method
type: spec