-
Notifications
You must be signed in to change notification settings - Fork 25
feat: Satisfy gd_req__arch_linkage_safety #557
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -715,6 +715,18 @@ Architecture Attributes | |
| Docs-as-Code shall enforce that valid safety architectural elements (Safety != QM) can | ||
| only be linked against valid safety architectural elements. | ||
|
|
||
| .. tool_req:: Check safety architecture view fulfils only safety requirements | ||
| :id: tool_req__docs_arch_link_safety_fulfils | ||
| :tags: Architecture | ||
| :implemented: YES | ||
| :version: 1 | ||
| :satisfies: gd_req__arch_linkage_safety | ||
| :parent_covered: YES | ||
|
|
||
| Enforce that valid ASIL architecture views | ||
| (``feat_arc_sta``, ``feat_arc_dyn``, ``comp_arc_sta``, ``comp_arc_dyn``) | ||
| "fulfil" only ASIL requirements. | ||
|
Comment on lines
+718
to
+728
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do we not already have a requirement that does this? Also this should be filtered against VALID only no?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Tricky question. We don't have check that in other cases. Any mandatory link may go an invalid item.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We do have this check here: i have to ask where the process requirement for this is again.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I believe
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe it's better to extend tool_req__docs_req_arch_link_safety_to_arch to cover all architecture elements AND views? Otherwise it feels like we spread the same requirement to multiple requirements. |
||
|
|
||
| .. tool_req:: Security: Restrict linkage | ||
| :id: tool_req__docs_arch_link_security | ||
| :tags: Architecture | ||
|
|
@@ -739,7 +751,7 @@ Architecture Attributes | |
| gd_req__arch_viewpoints, | ||
| :parent_covered: YES | ||
|
|
||
| Docs-as-Code shall enable the rendering of diagrams for the following architecture views: | ||
| Enable the rendering of diagrams for the following architecture views: | ||
|
|
||
| * Feature Package Diagram (feat_arc_sta) | ||
| * Feature Sequence Diagram (feat_arc_dyn) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1023,9 +1023,21 @@ graph_checks: | |
| include: feat_arc_sta, logic_arc_int, logic_arc_int_op, comp_arc_sta, real_arc_int, real_arc_int_op | ||
| condition: safety == QM | ||
| check: | ||
| fulfils: safety != QM | ||
| fulfils: safety == QM | ||
| explanation: An QM architecture element cannot implement ASIL requirements. | ||
|
|
||
| # req-Id: tool_req__docs_arch_link_safety_fulfils | ||
| tool_req__docs_arch_link_safety_fulfils: | ||
| needs: | ||
| include: feat_arc_sta, feat_arc_dyn, comp_arc_sta, comp_arc_dyn | ||
|
a-zw marked this conversation as resolved.
|
||
| condition: | ||
| and: | ||
| - safety != QM | ||
| - status == valid | ||
| check: | ||
| fulfils: safety != QM | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This has to be status == valid too.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same as the other comment: We don't require that for other links. |
||
| explanation: Safety-critical architecture views must only "fulfil" safety-critical architecture elements. | ||
|
|
||
| # req-Id: tool_req__docs_req_arch_link_safety_to_arch | ||
| tool_req__docs_req_arch_link_safety_to_arch: | ||
| needs: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,145 @@ | ||
| .. | ||
| # ******************************************************************************* | ||
| # Copyright (c) 2026 Contributors to the Eclipse Foundation | ||
| # | ||
| # See the NOTICE file(s) distributed with this work for additional | ||
| # information regarding copyright ownership. | ||
| # | ||
| # This program and the accompanying materials are made available under the | ||
| # terms of the Apache License Version 2.0 which is available at | ||
| # https://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # SPDX-License-Identifier: Apache-2.0 | ||
| # ******************************************************************************* | ||
|
|
||
| #CHECK: check_metamodel_graph | ||
|
|
||
| .. feat_req:: QM Feature Requirement Parent | ||
| :id: feat_req__test__qm_parent | ||
| :safety: QM | ||
| :status: valid | ||
|
|
||
| .. feat_req:: Safety Feature Requirement Parent | ||
| :id: feat_req__test__asil_parent | ||
| :safety: ASIL_B | ||
| :status: valid | ||
|
|
||
| .. comp_req:: QM Component Requirement Parent | ||
| :id: comp_req__test__qm_parent | ||
| :safety: QM | ||
| :status: valid | ||
|
|
||
| .. comp_req:: Safety Component Requirement Parent | ||
| :id: comp_req__test__asil_parent | ||
| :safety: ASIL_B | ||
| :status: valid | ||
|
|
||
|
|
||
| .. Negative Test: Safety feat_arc_sta fulfils a QM feat_req β should warn. | ||
| #EXPECT: feat_arc_sta__test__safety_to_qm: Parent need `feat_req__test__qm_parent` does not fulfill condition `safety != QM`. | ||
|
AlexanderLanin marked this conversation as resolved.
|
||
|
|
||
| .. feat_arc_sta:: Safety view with QM parent | ||
| :id: feat_arc_sta__test__safety_to_qm | ||
|
a-zw marked this conversation as resolved.
|
||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Positive Test: Safety feat_arc_sta fulfils a safety feat_req β should not warn. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. feat_arc_sta:: Safety view with safety parent | ||
| :id: feat_arc_sta__test__safety_to_asil | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__asil_parent | ||
|
|
||
|
|
||
| .. Positive Test: QM feat_arc_sta β check does not apply to QM elements. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. feat_arc_sta:: QM view with QM parent | ||
| :id: feat_arc_sta__test__qm_to_qm | ||
| :safety: QM | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Negative Test: Safety feat_arc_dyn fulfils a QM feat_req β should warn. | ||
| #EXPECT: feat_arc_dyn__test__safety_to_qm: Parent need `feat_req__test__qm_parent` does not fulfill condition `safety != QM`. | ||
|
a-zw marked this conversation as resolved.
|
||
|
|
||
| .. feat_arc_dyn:: Safety dynamic view with QM parent | ||
| :id: feat_arc_dyn__test__safety_to_qm | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Positive Test: Safety feat_arc_dyn fulfils a safety feat_req β should not warn. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. feat_arc_dyn:: Safety dynamic view with safety parent | ||
| :id: feat_arc_dyn__test__safety_to_asil | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__asil_parent | ||
|
|
||
|
|
||
| .. Positive Test: QM feat_arc_dyn β check does not apply to QM elements. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. feat_arc_dyn:: QM dynamic view with QM parent | ||
| :id: feat_arc_dyn__test__qm_to_qm | ||
| :safety: QM | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: feat_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Negative Test: Safety comp_arc_sta fulfils a QM comp_req β should warn. | ||
| #EXPECT: comp_arc_sta__test__safety_to_qm: Parent need `comp_req__test__qm_parent` does not fulfill condition `safety != QM`. | ||
|
a-zw marked this conversation as resolved.
|
||
|
|
||
| .. comp_arc_sta:: Safety component view with QM parent | ||
| :id: comp_arc_sta__test__safety_to_qm | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: comp_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Positive Test: Safety comp_arc_sta fulfils a safety comp_req β should not warn. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. comp_arc_sta:: Safety component view with safety parent | ||
| :id: comp_arc_sta__test__safety_to_asil | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: comp_req__test__asil_parent | ||
|
|
||
|
|
||
| .. Negative Test: Safety comp_arc_dyn fulfils a QM comp_req β should warn. | ||
| #EXPECT: comp_arc_dyn__test__safety_to_qm: Parent need `comp_req__test__qm_parent` does not fulfill condition `safety != QM`. | ||
|
a-zw marked this conversation as resolved.
|
||
|
|
||
| .. comp_arc_dyn:: Safety dynamic component view with QM parent | ||
| :id: comp_arc_dyn__test__safety_to_qm | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: comp_req__test__qm_parent | ||
|
|
||
|
|
||
| .. Positive Test: Safety comp_arc_dyn fulfils a safety comp_req β should not warn. | ||
| #EXPECT-NOT: fulfil | ||
|
|
||
| .. comp_arc_dyn:: Safety dynamic component view with safety parent | ||
| :id: comp_arc_dyn__test__safety_to_asil | ||
| :safety: ASIL_B | ||
| :security: NO | ||
| :status: valid | ||
| :fulfils: comp_req__test__asil_parent | ||
Uh oh!
There was an error while loading. Please reload this page.