diff --git a/tests/Feature/Api/PersonalAccessTokenRenewKillSwitchTest.php b/tests/Feature/Api/PersonalAccessTokenRenewKillSwitchTest.php index a00109d0c..9fd33fc75 100644 --- a/tests/Feature/Api/PersonalAccessTokenRenewKillSwitchTest.php +++ b/tests/Feature/Api/PersonalAccessTokenRenewKillSwitchTest.php @@ -2,6 +2,7 @@ use App\Models\User; use Illuminate\Foundation\Testing\LazilyRefreshDatabase; +use Illuminate\Routing\Middleware\ThrottleRequests; use Laravel\Passport\ClientRepository; uses(LazilyRefreshDatabase::class); @@ -19,7 +20,7 @@ uses(LazilyRefreshDatabase::class); */ beforeEach(function () { - $this->withoutMiddleware(\Illuminate\Routing\Middleware\ThrottleRequests::class); + $this->withoutMiddleware(ThrottleRequests::class); app(ClientRepository::class)->createPersonalAccessGrantClient( 'Test Personal Access Client', config('auth.guards.api.provider') diff --git a/tests/Feature/Api/ReblogDuplicateTest.php b/tests/Feature/Api/ReblogDuplicateTest.php index e34d091d5..a0d59ad87 100644 --- a/tests/Feature/Api/ReblogDuplicateTest.php +++ b/tests/Feature/Api/ReblogDuplicateTest.php @@ -1,5 +1,6 @@ postJson("/api/v1/statuses/{$status->id}/reblog")->assertOk(); // SharePipeline dispatched exactly once (only for the newly-created share). - Bus::assertDispatchedTimes(\App\Jobs\SharePipeline\SharePipeline::class, 1); + Bus::assertDispatchedTimes(SharePipeline::class, 1); }); diff --git a/tests/Feature/HashtagFollowProfileGuardTest.php b/tests/Feature/HashtagFollowProfileGuardTest.php index 6f4f54814..2b1503a4f 100644 --- a/tests/Feature/HashtagFollowProfileGuardTest.php +++ b/tests/Feature/HashtagFollowProfileGuardTest.php @@ -1,6 +1,7 @@ id)->delete(); + Profile::whereUserId($user->id)->delete(); $user->unsetRelation('profile'); $this->actingAs($user) diff --git a/tests/Feature/ImportInstagramMissingProfileTest.php b/tests/Feature/ImportInstagramMissingProfileTest.php index 1be8f1cd0..5c73a59b0 100644 --- a/tests/Feature/ImportInstagramMissingProfileTest.php +++ b/tests/Feature/ImportInstagramMissingProfileTest.php @@ -5,6 +5,7 @@ use App\Models\ImportJob; use App\Models\Profile; use App\Models\User; use Illuminate\Foundation\Testing\LazilyRefreshDatabase; +use Illuminate\Support\Str; uses(LazilyRefreshDatabase::class); @@ -29,7 +30,7 @@ it('drops the import job when the profile has been soft-deleted', function () { $job = new ImportJob; $job->profile_id = $user->profile_id; $job->service = 'instagram'; - $job->uuid = (string) \Illuminate\Support\Str::uuid(); + $job->uuid = (string) Str::uuid(); $job->stage = 0; $job->save(); @@ -50,7 +51,7 @@ it('drops the import job when the job no longer exists', function () { $job = new ImportJob; $job->profile_id = $user->profile_id; $job->service = 'instagram'; - $job->uuid = (string) \Illuminate\Support\Str::uuid(); + $job->uuid = (string) Str::uuid(); $job->stage = 0; $job->save();