Testing
ENTITY testing is designed around invariants and evidence boundaries, not only code coverage. A passing test means the tested condition passed in the documented environment; it does not automatically prove untested deployments, legal conclusions or external-world truth.
Reference regression
git clone https://github.com/blackmore-technology-group/ENTITY.git cd ENTITY git checkout v3.4.2 python -m pip install -r requirements.txt python -m compileall -q src sdk protocol python -m unittest discover -s tests -v
What to test
- Identity manifest/signature validity and invalid-key rejection.
- Authority scope and escalation rejection.
- Rights issuance/delegation/expiry/revocation.
- Canonicalization and cross-language result stability.
- Evidence and provenance preservation.
- Provider replacement, export, backup and recovery.
- Global Passport/profile/package conformance.
- BTDU exact reconstruction, object/evidence binding and topology boundaries.
- Market/economic lineage without invented ownership or value.
Negative testing
Invalid vectors are first-class. Tests should deliberately substitute originators, stewards, signatures, hashes, authorities, profiles, rights and provenance references and verify that the system fails closed.
Recovery tests
A meaningful destructive-recovery test captures pre-recovery roots, removes or isolates mutable state, restores from the qualified backup/export, then recomputes semantic/content roots and reverifies signatures/rights/evidence.
Environment-gated tests
Where a test requires ADAM source, hardware custody, multiple physical hosts or external data, record the gate explicitly instead of pretending a skipped test passed. v3.4.2's release notes identify the remaining external ADAM promotion gates as post-release evidence.