What the architecture preset checks
Pulsar's optional architecture preset checks a structural subset of the dependency rules. It is useful evidence for namespace boundaries, but review still owns the behavioral rules it cannot inspect.
Search for “Pest architecture test” when you need this optional structural evidence.
Copy the optional test deliberately
The package README gives the exact copy Command:
Context: optional architecture preset — Copy the package-maintained test into the consuming application.
cp vendor/faran/pulsar/presets/PulsarArchitectureTest.php tests/Arch/PulsarArchitectureTest.phpThe consuming application needs Pest’s architecture plugin. The preset is not installed automatically and this page does not add a dependency-install recipe.
Map the three structural rules
| Preset rule | Broader rule proved | Visible limit |
|---|---|---|
App\Pulsar\Domain does not use App\Pulsar\Services | Domain does not depend on Delivery. | It checks namespace use, not behavioral-call counts or every Domain rule. |
| Infrastructure does not use Services, discovered Domain Actions, or discovered Service UseCases, Operations, and Controllers | Infrastructure stays out of workflows and delivery. | It permits Domain Contracts and only sees existing matching directories. |
Discovered Controllers only use discovered Requests, Resources, UseCases, Domain DTOs, Value Objects, Enums, and Illuminate | Controller imports stay limited to delivery types, Domain values, and UseCases. | It skips absent Controller directories and does not prove exactly one UseCase call or forbid behavioral Query, Operation, or Action calls by itself. |
The dynamic glob sees only existing matching directories. That matters when reading the Infrastructure and Controller rules: absence of a directory can make a structural assertion unavailable rather than prove the dependency rules are unnecessary.
Keep the remaining rule set in review
The following remain review-only: exactly-one calls; UseCase-to-UseCase; Action, Operation, Query, Job, Command, Listener, Contract, transaction, and Event-emission rules; Service-to-Service behavior; passive-versus-behavioral distinctions; rare extension-point placement; and Adapter binding correctness. The preset checks namespace use, not behavioral call counts.
Use the dependency matrix as the normative behavioral rule set and placement table for generated and Laravel-owned locations. A passing copied preset is evidence for its three structural boundaries, not proof that the full architecture rules are enforced.