prplos/.gitlab/tests/cram/scripts
Petr Štetiar 15c1b5bd17
ci: cram: add diff-based component selection
Automatic component jobs need one reviewed source for path-to-board and
path-to-component decisions. Keeping that policy beside the existing
test buckets lets shared code classify changed tests consistently.

Add the six-board selection matrix and all board-specific,
cross-cutting, and explicit no-op paths. Validate the matrix while
loading the manifest.
Add a resolver for variable and label precedence, Git diffs, all-match
component unions, full collapse, empty reasons, and report output.

Exercise union routing, test classification, collapse, precedence,
stand-down reasons, defensive label errors, and six-board reporting
in an offline synthetic repository. Component coverage stays green.

Assisted-by: codex:gpt-5.6-sol
References: CI-9
Signed-off-by: Petr Štetiar <petr.stetiar@prplfoundation.org>
2026-08-26 20:37:08 +02:00
..
target ci: cram: obuspa: update expected DM & datamodel-dump script to scope with FEAT-9 integration 2026-06-02 15:16:11 +01:00
check-component-coverage.py ci: cram: add component manifest lint 2026-08-19 10:14:27 +00:00
cram_component_bucketing.py ci: cram: add diff-based component selection 2026-08-26 20:37:08 +02:00
prplmesh_ap_mld.sh ci: cram: use prplmesh-process-manager DM to check prplMesh status 2026-06-19 08:52:33 +00:00
README.md ci: cram: obuspa: verify obuspa datamodel fixtures on the DUT 2026-04-15 13:21:08 +02:00
resolve-changed-components.py ci: cram: add diff-based component selection 2026-08-26 20:37:08 +02:00
resolve-component-tests.py ci: cram: resolve comma-separated component unions 2026-08-26 20:37:07 +02:00
verify-obuspa-datamodel.sh ci: cram: obuspa: verify obuspa datamodel fixtures on the DUT 2026-04-15 13:21:08 +02:00
wifi.sh cram: add cram test for Radio.IEEE80211be.MLDUnitSetting 2026-08-07 16:16:23 +00:00

OBUSPA Test Scripts

This directory contains shared helper scripts used by cram tests.

verify-obuspa-datamodel.sh

verify-obuspa-datamodel.sh verifies the generic and cellular OBUSPA datamodel fixtures used by:

The helper uploads target/obuspa-datamodel-dump.sh to the DUT, captures the filtered datamodel on the DUT itself, copies the snapshot back to the host, and runs the comparison locally.

It supports two calling patterns:

  1. Single snapshot verification

    sh verify-obuspa-datamodel.sh \
      --mode generic \
      --expected path/to/obuspa.expected \
      --actual path/to/obuspa.actual \
      --diff path/to/obuspa.diff
    
  2. Before/after restart verification

    sh verify-obuspa-datamodel.sh \
      --mode generic \
      --expected path/to/obuspa.expected \
      --before-actual path/to/obuspa.before-restart.actual \
      --before-diff path/to/obuspa.before-restart.diff \
      --after-actual path/to/obuspa.after-restart.actual \
      --after-diff path/to/obuspa.after-restart.diff
    

In restart mode the helper:

  1. captures and verifies the before snapshot,
  2. runs service obuspa restart on the DUT,
  3. waits 20 seconds,
  4. captures and verifies the after snapshot.

Environment

The helper expects the same transport variables used by the cram tests:

  • CRAM_REMOTE_COMMAND for remote shell access
  • CRAM_REMOTE_COPY for file copies
  • TARGET_LAN_IP if the host cannot be derived from CRAM_REMOTE_COMMAND

CRAM_REMOTE_COPY defaults to scp when it is unset.

For local testing against Dropbear with newer OpenSSH clients, override the copy command explicitly, for example:

export CRAM_REMOTE_COPY='scp -O -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=ERROR'

On mismatches the helper prints the unified diff, saves the captured snapshot as *.actual, and saves the diff as *.diff.