|
| 1 | +# Marketplace Listing Contract Tests Validation |
| 2 | + |
| 3 | +PR: `PR_26152_084-marketplace-listing-contract-tests` |
| 4 | + |
| 5 | +## Scope |
| 6 | + |
| 7 | +- Added Marketplace Listing contract definition under `src/shared/contracts`. |
| 8 | +- Added Marketplace Listing fixture scenarios. |
| 9 | +- Added Marketplace Listing targeted contract test suite. |
| 10 | +- Added Marketplace Listing contract specification document. |
| 11 | +- No database, authentication, UI, HTML, CSS, payment, moderation, or runtime implementation changes. |
| 12 | + |
| 13 | +## Commands |
| 14 | + |
| 15 | +| Command | Result | |
| 16 | +| --- | --- | |
| 17 | +| `node --check src/shared/contracts/marketplaceListingContract.js` | PASS | |
| 18 | +| `node --check tests/shared/MarketplaceListingContract.test.mjs` | PASS | |
| 19 | +| `node tests/shared/MarketplaceListingContract.test.mjs` | PASS | |
| 20 | +| `node tests/shared/PublishContract.test.mjs` | PASS | |
| 21 | +| `node tests/shared/ReleaseContract.test.mjs` | PASS | |
| 22 | +| `node tests/shared/ProjectContract.test.mjs` | PASS | |
| 23 | +| `node tests/shared/IdentityPermissionsContract.test.mjs` | PASS | |
| 24 | +| `git diff --name-only -- '*.css' '*.html'` | PASS - no CSS or HTML changes | |
| 25 | +| `git diff --check` | PASS | |
| 26 | + |
| 27 | +## Contract Coverage |
| 28 | + |
| 29 | +Validated Marketplace Listing rules: |
| 30 | + |
| 31 | +- Listing requires owner. |
| 32 | +- Listing requires project. |
| 33 | +- Listing requires source Release. |
| 34 | +- Listing requires source Publish record. |
| 35 | +- Source Publish release linkage must match source Release. |
| 36 | +- Visibility must be one of `private`, `unlisted`, `public`, or `marketplace`. |
| 37 | +- Lifecycle status must be one of `draft`, `listed`, `unlisted`, or `retired`. |
| 38 | +- Listed and retired listings require `listedAt`. |
| 39 | +- Listed listings are immutable unless policy allows edits. |
| 40 | +- Retired listings remain historically referenceable. |
| 41 | +- Marketplace Listing access cannot bypass project ownership, visibility, or permissions. |
| 42 | + |
| 43 | +Validated forbidden leakage: |
| 44 | + |
| 45 | +- Runtime state rejected. |
| 46 | +- Auth state rejected. |
| 47 | +- Payment state rejected. |
| 48 | +- Moderation decision state rejected. |
| 49 | +- Tool state payload leakage rejected. |
| 50 | + |
| 51 | +## Samples Decision |
| 52 | + |
| 53 | +SKIP. This PR only changes shared contract definitions, contract fixtures, contract tests, docs/specs, and reports. Samples are not in scope. |
| 54 | + |
| 55 | +## Playwright |
| 56 | + |
| 57 | +Playwright impacted: No. This PR has no UI, runtime, tool behavior, rendering, or page changes. |
| 58 | + |
| 59 | +## Manual Validation |
| 60 | + |
| 61 | +1. Review `docs/dev/specs/MARKETPLACE_LISTING_CONTRACT.md`. |
| 62 | +2. Review `src/shared/contracts/marketplaceListingContract.js`. |
| 63 | +3. Confirm Marketplace Listing remains metadata-only and does not include runtime, auth, payment, or moderation decision state. |
| 64 | +4. Confirm `docs/dev/reports/codex_review.diff` and `docs/dev/reports/codex_changed_files.txt` exist for review. |
0 commit comments