Skip to content

test(dpp): restore ~60 commented-out/ignored tests#3122

Open
thepastaclaw wants to merge 12 commits intodashpay:v3.1-devfrom
thepastaclaw:fix/restore-commented-tests
Open

test(dpp): restore ~60 commented-out/ignored tests#3122
thepastaclaw wants to merge 12 commits intodashpay:v3.1-devfrom
thepastaclaw:fix/restore-commented-tests

Conversation

@thepastaclaw
Copy link
Collaborator

@thepastaclaw thepastaclaw commented Feb 20, 2026

Issue being fixed or feature implemented

Restore ~60 commented-out, ignored, and broken tests in rs-dpp that were silently disabled during API migrations. These tests cover critical paths: signing/validation, serialization, schema validation, and document factory operations.

Tracking issue: thepastaclaw/tracker#12.

What was done?

Nine incremental commits, one per fix area:

  1. C-05: Add missing #[test] attributes to schema_defs tests in v0/v1
  2. C-11: Fix copy-paste bug testing DocumentTypeV0 instead of DocumentTypeV1 in try_from_schema/v1
  3. C-02: Remove #[ignore] from 6 recursive_schema_validator tests
  4. C-03: Restore 10 commented-out DataContractV0 serialization tests (updated to current API)
  5. C-06: Restore DataContractUpdateTransition JSON conversion test
  6. C-04: Restore 5 commented-out DocumentFactory tests (updated to current API)
  7. C-01: Restore 19 commented-out signing trait tests (updated to current API)
  8. Fix 4 compilation errors against current API (import, type mismatch, missing arg, enum variant)
  9. Fix 7 runtime assertion failures (validator behavior changes, missing doc types, JSON serialization)

How Has This Been Tested?

  • cargo test -p dpp --lib523 passed, 0 failed
  • cargo test -p dpp (including doctests) → all pass
  • No production code changes — tests only, so no risk of behavioral regression
  • Each commit was verified individually to ensure incremental correctness
  • All restored tests exercise real code paths (signing, serialization, schema validation, document factory) — no stubs or mocks added

Validation

All DPP-related CI checks pass on the head commit (893becfe):

CI Check Result Duration
Rust packages (dpp) / Tests ✅ pass 2m 56s
Rust packages (dpp) / Check each feature ✅ pass 12m 38s
Rust packages (dpp) / Linting ✅ pass 2m 9s
Rust packages (dpp) / Formatting ✅ pass 35s
Rust packages (dpp) / Unused dependencies ✅ pass 1m 47s
Rust packages (dpp) / Detect immutable structure changes ✅ pass 12s

Downstream packages also pass (confirming no ripple effects from test-only changes):

CI Check Result Duration
Rust packages (drive) / Tests ✅ pass 7m 41s
Rust packages (drive-abci) / Tests ✅ pass 11m 32s
Rust packages (dash-sdk) / Tests ✅ pass 3m 35s
Rust packages (wasm-dpp) / Tests ✅ pass 2m 9s

Two pre-existing CI failures unrelated to this PR:

  • JS NPM security audit — known base-branch issue
  • Swift SDK build — known missing symbols issue (tracked in platform#3107)

Local validation (pre-push):

  • cargo test -p dpp --lib — 523 tests passed, 0 failed
  • cargo test -p dpp (full, including doctests) — all pass
  • Each of the 9 commits verified individually for incremental correctness

Breaking Changes

None. This PR contains only test code changes.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have added "!" to the title and described breaking changes in the corresponding section if my code contains any
  • I have made corresponding changes to the documentation if needed

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants