Skip to content

feat(onboarding): add public completion gate - #456

Open
guisaliba wants to merge 1 commit into
feat/squadsfrom
feat/349-onboarding-conclusion-gate
Open

feat(onboarding): add public completion gate#456
guisaliba wants to merge 1 commit into
feat/squadsfrom
feat/349-onboarding-conclusion-gate

Conversation

@guisaliba

Copy link
Copy Markdown

Closes #349

Summary

  • expose the tenancy-agnostic OnboardingCompletionGate contract with isCompleted and completedAt
  • keep Eloquent and onboarding models behind an internal adapter resolved through the service container
  • require an exact user, onboarding type, and completed status before opening the gate
  • return the persisted completion transition timestamp without exposing internal models

Tests

  • completed, in-progress, paused, rejected, missing, and mismatched-type gate behavior
  • persisted completion timestamp plus null behavior for incomplete and missing onboardings
  • contract resolution through the Laravel container

Verification

  • vendor/bin/pest --compact app-modules/onboarding/tests/Feature/OnboardingCompletionGateTest.php
  • make test (942 tests, 3,001 assertions)
  • npm run build
  • make test-rector
  • make test-pint
  • make phpstan

@guisaliba
guisaliba requested a review from a team July 26, 2026 21:00

@BrunaDomingues BrunaDomingues left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@arthurbazzz arthurbazzz left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stherzada stherzada linked an issue Jul 27, 2026 that may be closed by this pull request
3 tasks
@stherzada stherzada added this to the Onboarding milestone Jul 27, 2026
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.

feat(onboarding): gate público isCompleted(user, tenant, type)

6 participants