DCL Test Design - zigbee-alliance/distributed-compliance-ledger GitHub Wiki


πŸ“‹ DCL Modules – Test Design

This document provides a high-level overview of the test design strategies applied to each core module of the Distributed Compliance Ledger (DCL).

It focuses on verifying command behavior (CLI and REST), positive and negative parameter handling, role-based access control, and data consistency across the system after interactions.

The full Test Design with all use cases is placed in CSA-DCL-Queries-General.xlsx


🧩 Modules Covered

  • compliance – Certification, revocation, and compliance information for device models.
  • dclauth – Identity, roles, and access control for all actors in the ledger.
  • dclupgrade – Governance-based upgrade proposals and execution flow.
  • model – Device model definitions, updates, versioning, and metadata.
  • pki – Certificate authority logic (PAA/PAI), X.509 cert lifecycle (propose, approve, revoke).
  • validator – Node validator metadata, description, and approval process.
  • vendorinfo – Vendor registration, metadata, and public info publication.

βœ… Test Design Objectives

For each module, the following aspects are tested:

  • CLI & REST Command Behavior

    • Correct routing, return structure, and decoding
    • Endpoint availability and error feedback
  • Positive Input Scenarios

    • Valid arguments produce expected changes or outputs
    • Persistence and retrieval of state changes
  • Negative Input Scenarios

    • Empty, malformed, or unauthorized parameters
    • Missing required flags or conflicting values
  • Role-Based Access Validation

    • Trustee, Vendor, CertificationCenter, NodeAdmin, etc.
    • Unauthorized role attempts are rejected
  • Boundary Conditions

    • Min/max string lengths, ID formats, pagination, etc.
  • Post-Upgrade Compatibility

    • Commands still function after dclupgrade-driven chain upgrade

πŸ“Ž Usage

This test design serves as a foundation for:

  • Manual exploratory testing
  • Automated integration and regression test suites
  • Chain upgrade validation scenarios
  • QA traceability across DCL governance and certificate workflows

For detailed per-command cases, see each module’s test design CSA-DCL-Queries-General.xlsx.