diff --git a/.github/workflows/build_linux.yml b/.github/workflows/build_linux.yml index 93da27fc15..0670543c06 100644 --- a/.github/workflows/build_linux.yml +++ b/.github/workflows/build_linux.yml @@ -20,6 +20,8 @@ on: push: branches: - main + tags: + - "v*" merge_group: types: [checks_requested] workflow_call: @@ -32,6 +34,7 @@ jobs: matrix: include: - name: bl-x86_64-linux + artifact-name: x86_64-linux bazel-config: bl-x86_64-linux working-directory: "." bazel-build-target: "//..." @@ -40,6 +43,7 @@ jobs: -//score/language/safecpp/aborts_upon_exception:abortsuponexception_toolchain_test bazel-test-extra-flags: "" - name: bl-aarch64-linux + artifact-name: aarch64-linux bazel-config: bl-aarch64-linux working-directory: "." bazel-build-target: "//..." @@ -51,6 +55,7 @@ jobs: -//score/os/test:socket_test bazel-test-extra-flags: "--test_timeout=180,900,2700,10800" # Increase test timeout due to QEMU emulation - name: x86_64-linux (examples/integration) + artifact-name: x86_64-linux-integration bazel-config: x86_64-linux working-directory: "examples/integration" bazel-build-target: "//..." @@ -79,9 +84,31 @@ jobs: working-directory: ${{ matrix.working-directory }} run: | bazel test --config ${{ matrix.bazel-config }} ${{ matrix.bazel-test-extra-flags }} -- ${{ matrix.bazel-test-target }} - - name: Upload test logs on failure - if: failure() + - name: Upload test report + if: always() uses: actions/upload-artifact@v7 with: - name: bazel-testlogs-${{ matrix.name }} - path: ${{ matrix.working-directory }}/bazel-testlogs/**/test.log + name: test-report-${{ matrix.artifact-name }} + path: | + ${{ matrix.working-directory }}/bazel-testlogs/**/test.log + ${{ matrix.working-directory }}/bazel-testlogs/**/test.xml + retention-days: 5 + if-no-files-found: warn + docs-verify: + uses: eclipse-score/cicd-workflows/.github/workflows/docs-verify.yml@33842dcb0a19ca700d159101a34a7f078bada023 + permissions: + contents: read + with: + bazel-docs-verify-target: "//:docs_check" + docs-build: + needs: [docs-verify, linux-build-and-test] + # Still build docs (with whatever test results were uploaded) even if + # linux-build-and-test failed; only skip if docs-verify itself failed. + if: always() && needs.docs-verify.result == 'success' + uses: eclipse-score/cicd-workflows/.github/workflows/docs.yml@33842dcb0a19ca700d159101a34a7f078bada023 + permissions: + contents: read + with: + bazel-target: "//:docs" + retention-days: 5 + tests-report-artifact: "test-report-x86_64-linux" diff --git a/.github/workflows/docs_ci.yml b/.github/workflows/docs_ci.yml deleted file mode 100644 index 72df720587..0000000000 --- a/.github/workflows/docs_ci.yml +++ /dev/null @@ -1,42 +0,0 @@ -# ******************************************************************************* -# Copyright (c) 2025 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 -# ******************************************************************************* -name: Documentation CI -permissions: - contents: read -on: - pull_request: - types: [opened, reopened, synchronize] - push: - branches: - - main - tags: - - "v*" - release: - types: [published] - merge_group: - types: [checks_requested] -jobs: - docs-verify: - uses: eclipse-score/cicd-workflows/.github/workflows/docs-verify.yml@33842dcb0a19ca700d159101a34a7f078bada023 - permissions: - contents: read - with: - bazel-docs-verify-target: "//:docs_check" - docs-build: - needs: [docs-verify] - uses: eclipse-score/cicd-workflows/.github/workflows/docs.yml@33842dcb0a19ca700d159101a34a7f078bada023 - permissions: - contents: read - with: - bazel-target: "//:docs" - retention-days: 3 diff --git a/.github/workflows/docs_publish.yml b/.github/workflows/docs_publish.yml index 0ccbe1cfc1..28d545b566 100644 --- a/.github/workflows/docs_publish.yml +++ b/.github/workflows/docs_publish.yml @@ -13,7 +13,7 @@ name: Publish Documentation on: workflow_run: - workflows: ["Documentation CI"] + workflows: ["Bazel Build (Linux)"] types: [completed] permissions: actions: read diff --git a/docs/index.rst b/docs/index.rst index d6684fda52..01ddcd7cf6 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -59,4 +59,4 @@ The Components documentation provides detailed documentation for each individual Quick Start - Building and Testing ================================== -For build instructions, usage examples, and configuration options, refer to the `README `_ in the `eclipse-score/baselibs `_ repository. \ No newline at end of file +For build instructions, usage examples, and configuration options, refer to the `README `_ in the `eclipse-score/baselibs `_ repository. diff --git a/docs/verification_report/module_verification_report.rst b/docs/verification_report/module_verification_report.rst index f1e4572e46..aeb8cdf83a 100644 --- a/docs/verification_report/module_verification_report.rst +++ b/docs/verification_report/module_verification_report.rst @@ -39,6 +39,7 @@ Verification Report contains: - For external component Assumptions of Use: coverage by platform safety manual or feature/components incl. test case, passed/failed and completeness verdict - This is split in a list of QM requirements tested and a separate list of tests for ASIL rated requirements. - List of component requirements (ASIL rated) linked to inspection checklist and verdict (derived from PR export) + - See :ref:`requirements_statistics` for the generated requirements coverage statistics. **1.2. on Architecture** - List of component architecture tags tested by which test case, passed/failed and completeness verdict @@ -81,3 +82,8 @@ Verification Report contains: **Note1:** The verification report is valid for the module version tagged together with the report **Note2:** All the above lists are generated automatically + +.. toctree:: + :maxdepth: 1 + + requirements_statistics diff --git a/docs/verification_report/requirements_statistics.rst b/docs/verification_report/requirements_statistics.rst new file mode 100644 index 0000000000..09d6d39305 --- /dev/null +++ b/docs/verification_report/requirements_statistics.rst @@ -0,0 +1,64 @@ +.. _requirements_statistics: + +Component Requirements Statistics +================================= + +This page gives an overview of the component requirements (``comp_req``) defined for +baselibs: how many are valid, how many are covered by tests, and the current test +results. Use the tables below to drill down into individual requirements. + +.. raw:: html + + + +Overview +-------- + +.. needpie:: Requirements Status + :labels: invalid, valid and not tested, valid and tested + :colors: red,yellow, green + + type == 'comp_req' and status == 'invalid' + type == 'comp_req' and testlink == '' and (status == 'valid' or status == 'invalid') + type == 'comp_req' and testlink != '' and (status == 'valid' or status == 'invalid') + +.. needpie:: Test Results + :labels: passed, failed, skipped + :colors: green, red, orange + + type == 'testcase' and result == 'passed' + type == 'testcase' and result == 'failed' + type == 'testcase' and result == 'skipped' + +Requirements Without Tests +-------------------------- + +Valid requirements that are not yet covered by any test. + +.. needtable:: REQUIREMENTS WITHOUT TESTS + :filter: type == "comp_req" and status == "valid" and testlink == "" + :columns: id;title;satisfied_by as "Satisfied by";safety as "Safety" + :class: compact-needtable + +Requirements With Tests +----------------------- + +Valid requirements that are covered by at least one test, along with the tests +verifying them. + +.. needtable:: REQUIREMENTS WITH TESTS + :filter: type == "comp_req" and status == "valid" and testlink != "" + :columns: id;title;satisfied_by as "Satisfied by";safety as "Safety";testlink as "Tests" + :class: compact-needtable diff --git a/score/flatbuffers/details/flatfbuffer_allocator_test.cpp b/score/flatbuffers/details/flatfbuffer_allocator_test.cpp index f99188c368..8d6c4838f7 100644 --- a/score/flatbuffers/details/flatfbuffer_allocator_test.cpp +++ b/score/flatbuffers/details/flatfbuffer_allocator_test.cpp @@ -74,7 +74,7 @@ class SimpleAllocator : public ::flatbuffers::Allocator TEST(AllocatorTest, AllocateReturnsNonNull) { - RecordProperty("FullyVerifies", "::flatbuffers::Allocator::allocate, ::flatbuffers::Allocator::deallocate"); + RecordProperty("PartiallyVerifies", "comp_req__flatbuffers__serialization"); RecordProperty("Description", "allocate returns a non-null pointer; deallocate does not crash"); RecordProperty("TestType", "interface-test"); RecordProperty("DerivationTechnique", "equivalence-classes"); @@ -90,10 +90,10 @@ TEST(AllocatorTest, AllocateReturnsNonNull) TEST(AllocatorTest, AllocateSingleByte) { - RecordProperty("FullyVerifies", "::flatbuffers::Allocator::allocate, ::flatbuffers::Allocator::deallocate"); + RecordProperty("PartiallyVerifies", "comp_req__flatbuffers__serialization"); RecordProperty("Description", "allocate and deallocate a single byte"); RecordProperty("TestType", "interface-test"); - RecordProperty("DerivationTechnique", "boundary-value-analysis"); + RecordProperty("DerivationTechnique", "boundary-values"); SimpleAllocator alloc; uint8_t* ptr = alloc.allocate(1U); @@ -105,10 +105,10 @@ TEST(AllocatorTest, AllocateSingleByte) TEST(AllocatorTest, AllocateLargeRegion) { - RecordProperty("FullyVerifies", "::flatbuffers::Allocator::allocate, ::flatbuffers::Allocator::deallocate"); + RecordProperty("PartiallyVerifies", "comp_req__flatbuffers__serialization"); RecordProperty("Description", "allocate and deallocate a large (1 MiB) region"); RecordProperty("TestType", "interface-test"); - RecordProperty("DerivationTechnique", "boundary-value-analysis"); + RecordProperty("DerivationTechnique", "boundary-values"); SimpleAllocator alloc; constexpr size_t kSize = static_cast(1024U) * 1024U; // 1 MiB @@ -122,9 +122,7 @@ TEST(AllocatorTest, AllocateLargeRegion) TEST(AllocatorTest, UsableThroughBasePointer) { - RecordProperty("FullyVerifies", - "::flatbuffers::Allocator::allocate, ::flatbuffers::Allocator::deallocate, " - "::flatbuffers::Allocator::~Allocator"); + RecordProperty("PartiallyVerifies", "comp_req__flatbuffers__serialization"); RecordProperty("Description", "allocator is usable through a base-class pointer; virtual destructor is exercised"); RecordProperty("TestType", "interface-test"); RecordProperty("DerivationTechnique", "equivalence-classes"); @@ -155,7 +153,7 @@ class AllocatorGrowsBufferTest : public ::testing::TestWithParam