feat: TC8 SOME/IP conformance test suite for someipd - #60
Conversation
Wire-level pytest tests verifying someipd against the OA TC8 ECU Test Specification v3.0 Chapter 5: service discovery (phases, reboot, timing), message format, event notification, field lifecycle, and TCP transport. - someipd --tc8-standalone mode: request/response, field GET/SET, UDP and TCP events; offer_event uses ET_FIELD so vsomeip delivers the cached field value to new subscribers immediately on subscribe (is_field in JSON config is not honoured in programmatic offer_event calls) - vsomeip config templates for SD timing and service/event/field/TCP tests, with JSON Schema validation at lint time - Architecture doc, requirements, test specification and OA spec traceability - Bazel port isolation via the env attribute: each target receives unique SD and service ports enabling medium targets to run in parallel; timing-sensitive and reboot lifecycle targets retain the exclusive tag for serial execution
License Check Results🚀 The license check job ran with the Bazel command: bazel run //:license-checkStatus: Click to expand output |
|
The created documentation from the pull request is available at: docu-html |
- Raise check-added-large-files limit from 50 KB to 125 KB to accommodate large but legitimate TC8 test modules and the RST test specification document - Add REUSE.toml annotation for tests/tc8_conformance/config/*.json so the four vsomeip JSON config files pass reuse-lint-file - Prepend Apache-2.0 SPDX comment headers to the two TC8 README.md files that were missing copyright notices
TC8 conformance tests require special setup (multicast route, env vars) and already run in a dedicated step; avoid double-execution via -tc8 filter.
c507e28 to
63d628d
Compare
63d628d to
8420326
Compare
|
Documentation overall looks very good, reviewed the current state at https://eclipse-score.github.io/inc_someip_gateway/pr-60/architecture/tc8_conformance_testing.html - not in detail, but general sections and impression. Nice! On my local checkout, running the tests works with the expected failures:
$ time bazel test --test_tag_filters=tc8 --test_env=TC8_HOST_IP=127.0.0.1 //tests/tc8_conformance/...Result: real 6m16.073s |
|
I missed setting up the multicast... now the tests run fine locally as well, can confirm. |
mikehaller
left a comment
There was a problem hiding this comment.
As the TC8 Conformity Tests is a complete new part for someip gateway, I'll approve the current state of the PR. It's a very good step forward.
There is one issue regarding the main.cpp where I didn't fully grasp the plans and hence would accept it if it's just temporary.
- Use local json_schema_validator rule instead of @score_communication - Add integrity hashes to download_archive deps for reproducible builds - Add component descriptions for gatewayd and someipd in architecture docs
…C8 suite (eclipse-score#213) First in a 9-PR stack splitting eclipse-score#60 into reviewable slices. No test code yet, pure Bazel infrastructure: - Add `@score_itf` dev dep and upgrade `json_schema_validator` to 2.4.0 in `MODULE.bazel` - Add TC8 Bazel configs to `.bazelrc` and new `bazel/tools/` macros - Add `third_party/json_schema_validator/` BUILD rule - Minor BUILD adjustments across `score/` and `tests/benchmarks` - Raise pre-commit large-file limit to 125 KB; add REUSE entries for TC8 assets ## Stack | # | Branch | Scope | |---|--------|-------| | **1 (this)** | `jorgecasal/tc8-build-infra` | Bazel infra + deps | | 2 | `jorgecasal/tc8-someipd-standalone` | someipd `--tc8-standalone` flag | | 3 | `jorgecasal/tc8-itf-migration` | tests/common + ITF migration | | 4 | `jorgecasal/tc8-infra` | TC8 helpers, configs, conftest | | 5 | `jorgecasal/tc8-sd-core` | SD core tests | | 6 | `jorgecasal/tc8-sd-compliance` | SD format/reboot/robustness tests | | 7 | `jorgecasal/tc8-msg-format` | SOME/IP message format tests | | 8 | `jorgecasal/tc8-event-field` | Event/field/multi-service tests | | 9 | `jorgecasal/tc8-ci-docs` | CI workflows + documentation |
Remove TC8 mode from production someipd; introduce score/someipd_tc8 as a dedicated QM binary used exclusively by the conformance test suite.
Point BUILD and lifecycle helper at tc8_dut; add tc8_dut_config.json; align vsomeip config IDs with ETS spec; trim conftest docstrings.
…ts.py Replace per-file private constants with shared imports aligned to ETS spec values. Remove special characters from comments and strings throughout tc8_conformance.
Add TC8_SERVICE_ID and TC8_INSTANCE_ID substitution to config rendering in tc8_itf_conftest and dut_lifecycle. Fix routing manager name in tc8_someipd_multi.json from 'someipd' to 'tc8_dut'.
# Conflicts: # .bazelrc # BUILD # docs/requirements/stakeholder.rst # docs/tc8_conformance/requirements.rst # score/someipd/main.cpp # tests/tc8_conformance/helpers/__init__.py
|
Documentation preview for this pull request is available at: |
…ore#242) This is PR 2 of 9 in the TC8 conformance test suite stack (split from eclipse-score#60). Depends on: eclipse-score#213 (jorgecasal/tc8-build-infra), now merged into main. Note: Replaces the previously proposed PR eclipse-score#214 (jorgecasal/tc8-someipd-standalone), which was closed. The score/someipd_tc8/ standalone binary approach was replaced by the ETS stub described below. ## Changes score/someipd/main.cpp: migrate logging from std::cout to score::mw::log. No logic change. tests/tc8_conformance/application/ -- new ETS stub DUT: - shared/tc8_ets_service.h: service constants and event descriptors used by the stub - ets_stub/tc8_ets_stub.cpp: binary that offers tc8_service via mw::com GenericSkeleton and sends periodic event notifications for TC8 test capture - ets_stub/config/tc8_ets_stub_mw_com_config.json: mw::com manifest for the stub The ETS stub is the DUT application for TC8 conformance testing. It offers tc8_service via mw::com GenericSkeleton. gatewayd and someipd still run in the test setup and bridge that service to the SOME/IP network so the TC8 ETS can connect to it. Compared to the previous approach (a standalone someipd_tc8 binary), the ETS stub sits at the application layer and has no direct dependency on vsomeip or the IPC bridge internals. ## Stack | PR | Branch | Status | |----|--------|--------| | 1 | jorgecasal/tc8-build-infra | merged | | 2 | jorgecasal/tc8-ets-stub-dut | this PR | | 3 | jorgecasal/tc8-itf-migration | pending | | 4 | jorgecasal/tc8-infra | pending | | 5 | jorgecasal/tc8-sd-core | pending | | 6 | jorgecasal/tc8-sd-compliance | pending | | 7 | jorgecasal/tc8-msg-format | pending | | 8 | jorgecasal/tc8-event-field | pending | | 9 | jorgecasal/tc8-ci-docs | pending | ## Review focus - tc8_ets_stub.cpp: does the mw::com GenericSkeleton offer/notify flow correctly implement the event patterns expected by TC8 tests? - tc8_ets_service.h: are the event descriptors and DataTypeMetaInfo correct? - tc8_ets_stub_mw_com_config.json: are service ID, instance ID, and event IDs consistent with the TC8 test configs? - score/someipd/main.cpp: logging migration only, verify no logic regression.
|
Coverage report for this pull request: Status: failure (workflow run) The archive contains the HTML report, the raw LCOV data and the JUnit XML test results. |
Summary
Adds a TC8 SOME/IP conformance test suite for
someipd, covering the OA TC8 ECU Test Specification. The suite runs under the Integration Test Framework (ITF): pytest runs on the host and drivessomeipdinside a QEMU guest (Linux or QNX8) over SSH on a TAP bridge, while the host sends and receives raw SOME/IP UDP/TCP to the device under test. A--tc8-standaloneflag letssomeipdoffer services directly without the full gateway stack.Scope: 185 test cases across 10 test modules, plus documentation and CI integration.
Scope of
--tc8-standalone: These conformance tests validatesomeipdwire-level SOME/IP behavior only. They do not exercise the fullmw::comtogatewaydtosomeipdmiddleware path. End-to-end verification of that path is out of scope for this suite.What's included
Tests (
tests/tc8_conformance/)someip_capture.pcapvia tcpdump on the host TAP interfacexfailfor known vsomeip 3.6.1 limitations (2 in message format, 1 in service discovery)Documentation (
docs/)someipd (
src/someipd/main.cpp)--tc8-standaloneflag offers test services directly without gatewayd IPCET_FIELDso vsomeip sends the initial field value on subscribeBuild and CI
bazel test --config=tc8-itf //tests/tc8_conformance/...on Linux andbazel test --config=tc8-itf-qnx //tests/tc8_conformance/...on QNX8//tests/common:capturehelper library and@score_itfdevelopment dependencyjson_schema_validatorupgraded to 2.4.0; unusedjsonschemaPython dependency removedtests/integration/BUILD.bazelmigrated frompy_pytesttoscore_py_pytest.pre-commit-config.yamllarge file limit raised from 50KB to 125KB for TC8 assets