Harden SyncPoliciesJob type input parsing + fail fast when supported types are empty/mismatched. Pass supported policy types from Tenant sync action and add regression tests. Co-authored-by: Ahmed Darrazi <ahmeddarrazi@adsmac.fritz.box> Reviewed-on: #75
20 lines
644 B
Markdown
20 lines
644 B
Markdown
# 999 - Fix seeding: tenants.external_id not-null
|
|
|
|
## Problem
|
|
Running `php artisan migrate:fresh --seed` fails with:
|
|
|
|
- `SQLSTATE[23502]: Not null violation: null value in column "external_id" of relation "tenants"`
|
|
|
|
The failing insert is from `Database\Seeders\PoliciesSeeder` creating a default tenant without populating `external_id`.
|
|
|
|
## Goal
|
|
- `migrate:fresh --seed` succeeds on a clean database.
|
|
|
|
## Non-goals
|
|
- No changes to production data or existing tenant records.
|
|
|
|
## Acceptance Criteria
|
|
- Seeding succeeds with PostgreSQL.
|
|
- A default tenant is created with a valid `external_id`.
|
|
- Tests covering the seeding path (minimal) pass.
|