mirror of
https://github.com/coollabsio/coolify.git
synced 2026-11-12 15:53:46 -04:00
Mixed tests keep their behavior checks. Also fix two stale tests: the runtime logs tests set a locked property, and the registry test identifies the instance database by id 0.
23 lines
616 B
PHP
23 lines
616 B
PHP
<?php
|
|
|
|
use App\Models\InstanceSettings;
|
|
use App\Models\Team;
|
|
use App\Models\User;
|
|
use Illuminate\Foundation\Testing\RefreshDatabase;
|
|
|
|
uses(RefreshDatabase::class);
|
|
|
|
beforeEach(function () {
|
|
InstanceSettings::unguarded(fn () => InstanceSettings::query()->create(['id' => 0]));
|
|
$user = User::factory()->create();
|
|
$team = Team::factory()->create();
|
|
$user->teams()->attach($team, ['role' => 'owner']);
|
|
$this->actingAs($user);
|
|
session(['currentTeam' => $team]);
|
|
$this->team = $team;
|
|
});
|
|
|
|
it('registers the metrics route', function () {
|
|
expect(route('metrics'))->toEndWith('/metrics');
|
|
});
|