34 lines
879 B
PHP
34 lines
879 B
PHP
<?php
|
|
|
|
namespace Database\Factories;
|
|
|
|
use App\Models\ProviderConnection;
|
|
use App\Models\Tenant;
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
/**
|
|
* @extends Factory<ProviderConnection>
|
|
*/
|
|
class ProviderConnectionFactory extends Factory
|
|
{
|
|
protected $model = ProviderConnection::class;
|
|
|
|
public function definition(): array
|
|
{
|
|
return [
|
|
'tenant_id' => Tenant::factory(),
|
|
'provider' => 'microsoft',
|
|
'entra_tenant_id' => fake()->uuid(),
|
|
'display_name' => fake()->company(),
|
|
'is_default' => false,
|
|
'status' => 'needs_consent',
|
|
'health_status' => 'unknown',
|
|
'scopes_granted' => [],
|
|
'last_health_check_at' => null,
|
|
'last_error_reason_code' => null,
|
|
'last_error_message' => null,
|
|
'metadata' => [],
|
|
];
|
|
}
|
|
}
|