Skip to content

chore: set up Workbench for local package development#74

Merged
jfrosorio merged 2 commits into
masterfrom
chore-73
Jul 16, 2026
Merged

chore: set up Workbench for local package development#74
jfrosorio merged 2 commits into
masterfrom
chore-73

Conversation

@jfrosorio

@jfrosorio jfrosorio commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Closes #73.

Enables testing the package against the real Eupago sandbox directly from a clone — no separate host application needed.

After comparing ecosystem conventions (laravel/passport commits a full Workbench scaffold; spatie/laravel-data and filament commit only a testbench.yaml), this takes the minimal route:

  • testbench.yaml registers EuPagoServiceProvider and the package migrations path, so the Testbench CLI boots with the package loaded: vendor/bin/testbench tinker / migrate / serve.
  • Credentials live in a root .env (read by the Testbench CLI, never committed); .env.example documents the expected keys.
  • .gitignore now covers .env files — previously a root .env with real credentials was one git add . away from being committed.
  • CONTRIBUTING documents the workflow.

No workbench/ folder, no composer.json changes — a full Workbench scaffold can be added later with one command if a demo app is ever needed.

Verified locally: config:show eupago resolves the package config with .env values, tinker instantiates package classes, migrate runs all five package migrations, and the full quality suite passes (Pest, Pint, PHPStan).

@jfrosorio
jfrosorio requested a review from Copilot July 16, 2026 15:59
@jfrosorio jfrosorio self-assigned this Jul 16, 2026
@jfrosorio jfrosorio added the chore Tasks to be performed. label Jul 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Adds a Laravel Workbench/Testbench setup to this package so contributors can boot and exercise the EuPago integration directly from a clone (tinker, migrate, serve) without creating a separate host Laravel application.

Changes:

  • Adds Workbench scaffold under workbench/ (routes, minimal app structure, model/factory/seeder, env example).
  • Introduces testbench.yaml plus Composer scripts/autoload-dev entries to support Workbench discovery/build/serve flows.
  • Updates contributor docs and gitignore to document the workflow and prevent accidental credential commits.

Reviewed changes

Copilot reviewed 11 out of 17 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
workbench/routes/web.php Adds a default web route for the Workbench app.
workbench/routes/console.php Adds a console routes stub for the Workbench app.
workbench/resources/views/.gitkeep Tracks the Workbench views directory.
workbench/database/seeders/DatabaseSeeder.php Adds a sample seeder for the Workbench app database.
workbench/database/migrations/.gitkeep Tracks the Workbench migrations directory.
workbench/database/factories/UserFactory.php Adds a sample User factory for Workbench.
workbench/database/factories/.gitkeep Tracks the Workbench factories directory.
workbench/bootstrap/.gitkeep Tracks the Workbench bootstrap directory.
workbench/app/Providers/WorkbenchServiceProvider.php Adds a stub service provider for Workbench customization.
workbench/app/Models/User.php Adds a sample User model for Workbench.
workbench/app/Models/.gitkeep Tracks the Workbench models directory.
workbench/.env.example Documents required Eupago sandbox env keys for local Workbench usage.
testbench.yaml Configures Testbench/Workbench bootstrapping and build steps.
CONTRIBUTING.md Documents the local Workbench-based workflow (tinker/migrate/serve).
composer.json Adds Workbench autoload-dev namespaces and Composer scripts for discovery/build/serve.
.gitignore Ignores .env files to reduce risk of committing credentials.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread workbench/routes/web.php Outdated
Comment thread testbench.yaml
@jfrosorio
jfrosorio merged commit d7cc659 into master Jul 16, 2026
13 checks passed
@jfrosorio
jfrosorio deleted the chore-73 branch July 16, 2026 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore Tasks to be performed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore: set up Workbench for local package development

2 participants