Skip to content

S010: Testing, CI/CD & Binary Distribution

FieldValue
SpecS010
FeatureTesting, CI/CD & Binary Distribution
Date2026-04-24
StatusImplemented
Authorspec-writer-agent

Overview

Parity's quality gates span three coordinated systems: a Pest-based test suite validating rules, coverage readers, release automation, samples, and CLI behavior; a GitHub Actions CI job running the release-quality gates on branch pushes and pull requests; and a Box-based PHAR pipeline that packages the application for users with PHP 8.4 and zlib. Laravel Pint enforces code style, and the release process governs curated changelog promotion, version verification, atomic tagging, Packagist smoke testing, and GitHub Release publication.

This specification defines the complete contract for all four areas: test suite structure and coverage expectations, CI/CD workflow jobs and triggers, binary distribution via Box PHAR, and the end-to-end release process. It serves as the source of truth for implementation (S010-FR), acceptance testing (S010-AS), QA edge-case coverage (S010-EC), non-functional constraints (S010-NF), and measurable success criteria (S010-SC).

User Scenarios

S010-US-001 [P1] As a developer, I want one documented covered Pest command so that I can verify all Parity functionality locally before pushing.

S010-US-002 [P1] As a CI pipeline, I want to run dependency, style, test, self-check, artifact, and PHAR gates in a deterministic sequence so that failures remain attributable.

S010-US-003 [P1] As a developer, I want the CI pipeline to fail if code style violations exist so that style drift is never merged.

S010-US-004 [P1] As a maintainer, I want a curated release command to align the changelog, source version, annotated tag, PHAR, Packagist package, and GitHub Release so that publication is consistent and auditable.

S010-US-005 [P2] As a user with PHP 8.4 and zlib, I want to download a standalone PHAR binary so that I can use Parity without adding Composer dependencies to my project.

S010-US-006 [P2] As a package author, I want to verify that my plugin rules are tested in Parity's CI so that custom rule authors have a reference implementation.

Requirements Summary

IDTypePriorityTitleStatus
S010-FR-001FunctionalP1Test suite organizationImplemented
S010-FR-002FunctionalP1Test naming conventionsImplemented
S010-FR-003FunctionalP1Pest configurationImplemented
S010-FR-004FunctionalP1Coverage report generationImplemented
S010-FR-005FunctionalP1Spec ID traceability in testsImplemented
S010-FR-006FunctionalP1CI pipeline triggersImplemented
S010-FR-007FunctionalP1CI lint gateImplemented
S010-FR-008FunctionalP1CI test gateImplemented
S010-FR-009FunctionalP1CI self-check gateImplemented
S010-FR-010FunctionalP1CI artifact publicationImplemented
S010-FR-011FunctionalP1Box PHAR compilationImplemented
S010-FR-012FunctionalP1PHAR distribution mechanismImplemented
S010-FR-013FunctionalP1Release version consistencyImplemented
S010-FR-014FunctionalP1Laravel Pint integrationImplemented
S010-FR-015FunctionalP1Release version bumpingImplemented
S010-FR-016FunctionalP1Curated changelog promotionImplemented
S010-FR-017FunctionalP1Atomic git taggingImplemented
S010-FR-018FunctionalP1Gated GitHub Release creationImplemented
S010-FR-019FunctionalP1Sample project matrixImplemented
S010-AS-001AcceptanceP1Full test suite passes locallyImplemented
S010-AS-002AcceptanceP1CI pipeline runs on branch pushImplemented
S010-AS-003AcceptanceP1CI pipeline runs on pull requestsImplemented
S010-AS-004AcceptanceP1CI lint gate fails on style violationsImplemented
S010-AS-005AcceptanceP1CI test gate fails on test failuresImplemented
S010-AS-006AcceptanceP1PHAR compiles successfullyImplemented
S010-AS-007AcceptanceP1PHAR runs Parity check successfullyImplemented
S010-AS-008AcceptanceP1Release script aligns VERSION and changelogImplemented
S010-AS-009AcceptanceP1Release script atomically pushes commit and tagImplemented
S010-AS-010AcceptanceP1Packagist smoke gates GitHub ReleaseImplemented
S010-AS-011AcceptanceP1Sample project configs passImplemented
S010-AS-012AcceptanceP1Release metadata mismatch is rejectedImplemented
S010-EC-001Edge CaseP1Test lacks a traceability commentDocumented
S010-EC-002Edge CaseP1Coverage below threshold triggers CI failureImplemented
S010-EC-003Edge CaseP1Box PHAR compilation failureImplemented
S010-EC-004Edge CaseP2Pint detects a CI style violationImplemented
S010-EC-005Edge CaseP1Release script run on dirty git stateImplemented
S010-EC-006Edge CaseP2Composer dependencies unavailable during PHAR buildImplemented
S010-EC-007Edge CaseP1Duplicate release tagImplemented
S010-EC-008Edge CaseP1GitHub Release asset upload failureImplemented
S010-EC-009Edge CaseP1CI runs on a forkImplemented
S010-EC-010Edge CaseP1PHPUnit XML coverage is unavailableImplemented
S010-EC-011Edge CaseP1Release attempted outside mainImplemented
S010-NF-001Non-FunctionalP1Test suite executes in under 60 secondsVerified
S010-NF-002Non-FunctionalP1CI pipeline completes in under 5 minutesVerified
S010-NF-003Non-FunctionalP2PHAR binary under 30MiB targetVerified
S010-NF-004Non-FunctionalP2Main remains Pint-cleanVerified
S010-NF-005Non-FunctionalP2PHPStan when configuredNot configured
S010-SC-001SuccessP1Covered Pest suite passesVerified
S010-SC-002SuccessP1All CI gates green on mainVerified
S010-SC-003SuccessP1PHAR binary is executable and self-containedVerified
S010-SC-004SuccessP1Release assets are checksummed and attachedImplemented
S010-SC-005SuccessP1Samples cover supported stacksVerified
S010-SC-006SuccessP1Version identity is consistent across channelsImplemented
S010-SC-007SuccessP1Changelog contains curated release notesVerified
S010-SC-008SuccessP1Exact Packagist release passes check and testImplemented

Cross-Spec Dependencies

  • Depends on: S001 (CLI Commands -- parity check and parity init are exercised by the test suite and CI), S002 (Rules System -- rule implementations are unit-tested), S003 (Coverage Readers -- coverage readers are tested with fixture files), S004 (Coverage Linkers -- linker implementations have dedicated Pest tests), S005 (Plugin System -- plugin loading is exercised in integration tests)
  • Required by: N/A (this is a foundational infrastructure spec)