Skip to content

Run the full unit suite on pull requests - #1082

Merged
rmcdaniel merged 6 commits into
mainfrom
workflow/pr-full-unit-suite
Nov 11, 2026
Merged

rmcdaniel merged 6 commits into
mainfrom
workflow/pr-full-unit-suite

Conversation

@rmcdaniel

Copy link
Copy Markdown
Member

Main's coverage-unit runs the whole unit suite only after merge. PRs ran a fixed list of database-independent unit contracts, so a unit test that only fails in the full suite could merge green. #1074's Laravel Cloud timer test did exactly that, and main has been red since (fix: #1081).

Change

  • New pr-unit job, on pull requests only. It runs vendor/bin/phpunit --testsuite unit without coverage, with the same SQLite-file database, Redis service and environment as coverage-unit. It depends only on preflight, so it runs in parallel with the other PR jobs.
  • The build gate now requires pr-unit to succeed on PRs and be skipped on pushes.
  • test-build-routing.py gains a test for that contract. All 22 routing tests pass locally.

Cost: one more runner per PR. The unit suite without coverage took about 6 minutes in a container, against about 22 minutes for coverage-unit with PCOV, and PR builds already take about 7.5 minutes. I'll confirm the actual duration from this PR's run. pr-unit-contracts stays as it is, since it covers special environments such as file-backed SQLite concurrency and continuation profiles.

This PR's own pr-unit will fail on the known TimersTest until #1081 merges. I'll update the branch then.

🤖 Generated with Claude Code

coverage-unit runs the unit suite only after merge, so a unit test that
fails there could merge green. #1074's Laravel Cloud timer test did exactly
that. A new pr-unit job runs the same suite without coverage, with the same
SQLite and Redis setup, and the build gate requires it on pull requests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@rmcdaniel

Copy link
Copy Markdown
Member Author

Measured on this PR: pr-unit passed in 11.6 min, now the longest PR job. Next longest: pr-tracing 7.1 min, pr-unit-contracts 5.0 min, pr-feature-mysql 4.8 min. That adds about 4.5 min to PR wall time. If that becomes the bottleneck, the next step is splitting pr-unit into two shards. Updated onto main after #1077; will merge when green.

@sonarqubecloud

Copy link
Copy Markdown

@rmcdaniel
rmcdaniel merged commit 46ca8f6 into main Nov 11, 2026
25 checks passed
@rmcdaniel
rmcdaniel deleted the workflow/pr-full-unit-suite branch November 11, 2026 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant