From d1d1be7586847395a6ab49e4c60f022457cee64d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Falc=C3=B3n?= Date: Thu, 12 Feb 2026 09:58:01 +0100 Subject: [PATCH] Remove budgets feature flag (#108) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary - Remove the `budgets` Pennant feature flag — budgets is now enabled for all users - Delete `EnsureBudgetsFeature` middleware and its route guard - Remove `budgets` from shared Inertia features and the `Features` TypeScript interface - Remove all `Feature::for($user)->activate('budgets')` calls from tests - Delete `BudgetFeatureFlagTest` and feature-disabled test cases from `BudgetsFeatureNavigationTest` --- .../Commands/Concerns/ResolvesFeatures.php | 2 +- .../Commands/ResetDemoAccountCommand.php | 8 -- app/Http/Middleware/EnsureBudgetsFeature.php | 29 ----- app/Http/Middleware/HandleInertiaRequests.php | 1 - app/Listeners/AssignTransactionToBudget.php | 4 +- .../UnassignTransactionFromBudget.php | 4 +- app/Providers/AppServiceProvider.php | 1 - bootstrap/app.php | 2 - resources/js/providers/menu-item-provider.tsx | 9 +- resources/js/types/index.d.ts | 1 - routes/web.php | 2 +- tests/Browser/BudgetCrudTest.php | 7 -- .../Browser/BudgetsFeatureNavigationTest.php | 32 ----- tests/Feature/BudgetFeatureFlagTest.php | 114 ------------------ .../BudgetHistoricalAssignmentTest.php | 2 - tests/Feature/BudgetPeriodDateTest.php | 3 - tests/Feature/BudgetTest.php | 11 -- tests/Feature/TransactionTest.php | 3 - 18 files changed, 7 insertions(+), 228 deletions(-) delete mode 100644 app/Http/Middleware/EnsureBudgetsFeature.php delete mode 100644 tests/Feature/BudgetFeatureFlagTest.php diff --git a/app/Console/Commands/Concerns/ResolvesFeatures.php b/app/Console/Commands/Concerns/ResolvesFeatures.php index e908d0d0..f8c71dc3 100644 --- a/app/Console/Commands/Concerns/ResolvesFeatures.php +++ b/app/Console/Commands/Concerns/ResolvesFeatures.php @@ -49,6 +49,6 @@ trait ResolvesFeatures private function getStringBasedFeatures(): array { - return ['budgets', 'plaintext-transactions', 'open-banking', 'account-mapping']; + return ['plaintext-transactions', 'open-banking', 'account-mapping']; } } diff --git a/app/Console/Commands/ResetDemoAccountCommand.php b/app/Console/Commands/ResetDemoAccountCommand.php index 604a3653..15dd4875 100644 --- a/app/Console/Commands/ResetDemoAccountCommand.php +++ b/app/Console/Commands/ResetDemoAccountCommand.php @@ -21,7 +21,6 @@ use App\Services\Demo\DemoLabelsProvider; use App\Services\Demo\DemoTransactionsProvider; use Illuminate\Console\Command; use Illuminate\Support\Collection; -use Laravel\Pennant\Feature; class ResetDemoAccountCommand extends Command { @@ -77,8 +76,6 @@ class ResetDemoAccountCommand extends Command $this->createBudgets($user); - $this->enableBudgetsFeature($user); - $this->assignTransactionsToBudgets($user); $this->createSubscription($user); @@ -510,11 +507,6 @@ class ResetDemoAccountCommand extends Command } } - private function enableBudgetsFeature(User $user): void - { - Feature::for($user)->activate('budgets'); - } - private function assignTransactionsToBudgets(User $user): void { $transactions = $user->transactions()->get(); diff --git a/app/Http/Middleware/EnsureBudgetsFeature.php b/app/Http/Middleware/EnsureBudgetsFeature.php deleted file mode 100644 index 27391522..00000000 --- a/app/Http/Middleware/EnsureBudgetsFeature.php +++ /dev/null @@ -1,29 +0,0 @@ -user(); - - if (! $user || ! Feature::for($user)->active('budgets')) { - abort(404); - } - - return $next($request); - } -} diff --git a/app/Http/Middleware/HandleInertiaRequests.php b/app/Http/Middleware/HandleInertiaRequests.php index d32cef2f..1bd03533 100644 --- a/app/Http/Middleware/HandleInertiaRequests.php +++ b/app/Http/Middleware/HandleInertiaRequests.php @@ -69,7 +69,6 @@ class HandleInertiaRequests extends Middleware 'sidebarOpen' => ! $request->hasCookie('sidebar_state') || $request->cookie('sidebar_state') === 'true', 'features' => [ 'cashflow' => true, - 'budgets' => $user ? Feature::for($user)->active('budgets') : false, 'plaintext-transactions' => $user ? Feature::for($user)->active('plaintext-transactions') : false, 'open-banking' => $user ? Feature::for($user)->active('open-banking') : false, 'account-mapping' => $user ? Feature::for($user)->active('account-mapping') : false, diff --git a/app/Listeners/AssignTransactionToBudget.php b/app/Listeners/AssignTransactionToBudget.php index 9a0253ed..6e105541 100644 --- a/app/Listeners/AssignTransactionToBudget.php +++ b/app/Listeners/AssignTransactionToBudget.php @@ -6,7 +6,6 @@ use App\Events\TransactionCreated; use App\Events\TransactionUpdated; use App\Services\BudgetTransactionService; use Illuminate\Contracts\Queue\ShouldQueue; -use Laravel\Pennant\Feature; class AssignTransactionToBudget implements ShouldQueue { @@ -15,9 +14,8 @@ class AssignTransactionToBudget implements ShouldQueue public function handle(TransactionCreated|TransactionUpdated $event): void { $transaction = $event->transaction; - $user = $transaction->user; - if (! $user || ! Feature::for($user)->active('budgets')) { + if (! $transaction->user) { return; } diff --git a/app/Listeners/UnassignTransactionFromBudget.php b/app/Listeners/UnassignTransactionFromBudget.php index 9be70f47..2ebacea1 100644 --- a/app/Listeners/UnassignTransactionFromBudget.php +++ b/app/Listeners/UnassignTransactionFromBudget.php @@ -5,7 +5,6 @@ namespace App\Listeners; use App\Events\TransactionDeleted; use App\Services\BudgetTransactionService; use Illuminate\Contracts\Queue\ShouldQueue; -use Laravel\Pennant\Feature; class UnassignTransactionFromBudget implements ShouldQueue { @@ -14,9 +13,8 @@ class UnassignTransactionFromBudget implements ShouldQueue public function handle(TransactionDeleted $event): void { $transaction = $event->transaction; - $user = $transaction->user; - if (! $user || ! Feature::for($user)->active('budgets')) { + if (! $transaction->user) { return; } diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php index c3f1ca75..16a11b60 100644 --- a/app/Providers/AppServiceProvider.php +++ b/app/Providers/AppServiceProvider.php @@ -48,7 +48,6 @@ class AppServiceProvider extends ServiceProvider return Limit::perSecond(30); }); - Feature::define('budgets', fn (User $user) => true); Feature::define('plaintext-transactions', fn (User $user) => false); Feature::define('open-banking', fn (User $user) => false); Feature::define('account-mapping', fn (User $user) => false); diff --git a/bootstrap/app.php b/bootstrap/app.php index c9147cc9..f16a03a5 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -1,6 +1,5 @@ EnsureUserIsSubscribed::class, 'onboarded' => \App\Http\Middleware\EnsureOnboardingComplete::class, 'block-demo' => \App\Http\Middleware\BlockDemoAccountActions::class, - 'budgets' => EnsureBudgetsFeature::class, 'open-banking' => EnsureOpenBankingFeature::class, ]); }) diff --git a/resources/js/providers/menu-item-provider.tsx b/resources/js/providers/menu-item-provider.tsx index dbaf5b97..d2bc22f9 100644 --- a/resources/js/providers/menu-item-provider.tsx +++ b/resources/js/providers/menu-item-provider.tsx @@ -44,16 +44,13 @@ export function getMainNavItems(features: Features): NavItem[] { href: transactionsIndex(), icon: Receipt, }, - ); - - if (features.budgets) { - items.push({ + { type: 'nav-item', title: 'Budgets', href: budgetsIndex(), icon: PiggyBank, - }); - } + }, + ); return items; } diff --git a/resources/js/types/index.d.ts b/resources/js/types/index.d.ts index 7f7c012d..c0dc7f76 100644 --- a/resources/js/types/index.d.ts +++ b/resources/js/types/index.d.ts @@ -40,7 +40,6 @@ export interface NavDivider { export interface Features { cashflow: boolean; - budgets: boolean; 'plaintext-transactions': boolean; 'open-banking': boolean; 'account-mapping': boolean; diff --git a/routes/web.php b/routes/web.php index 1bb581b7..4c00cd30 100644 --- a/routes/web.php +++ b/routes/web.php @@ -72,7 +72,7 @@ Route::middleware(['auth', 'verified', 'onboarded', 'subscribed', 'open-banking' Route::post('connections/{connection}/map-accounts', [AccountMappingController::class, 'store'])->name('open-banking.map-accounts.store'); }); -Route::middleware(['auth', 'verified', 'onboarded', 'subscribed', 'budgets'])->group(function () { +Route::middleware(['auth', 'verified', 'onboarded', 'subscribed'])->group(function () { Route::get('budgets', [BudgetController::class, 'index'])->name('budgets.index'); Route::post('budgets', [BudgetController::class, 'store'])->name('budgets.store'); Route::get('budgets/{budget}', [BudgetController::class, 'show'])->name('budgets.show'); diff --git a/tests/Browser/BudgetCrudTest.php b/tests/Browser/BudgetCrudTest.php index a2ecd6bf..b7d64c36 100644 --- a/tests/Browser/BudgetCrudTest.php +++ b/tests/Browser/BudgetCrudTest.php @@ -3,11 +3,9 @@ use App\Models\Budget; use App\Models\Category; use App\Models\User; -use Laravel\Pennant\Feature; test('user can create a budget with category', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create([ 'user_id' => $user->id, @@ -58,7 +56,6 @@ test('user can create a budget with category', function () { test('user can update budget name', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -96,7 +93,6 @@ test('user can update budget name', function () { test('user can delete a budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -133,7 +129,6 @@ test('user can delete a budget', function () { test('budget creation validates required fields', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/budgets'); $page->wait(2); // Wait for page to fully load @@ -151,7 +146,6 @@ test('budget creation validates required fields', function () { test('budget shows current period information', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -168,7 +162,6 @@ test('budget shows current period information', function () { test('user can navigate back to budgets list from budget detail', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ diff --git a/tests/Browser/BudgetsFeatureNavigationTest.php b/tests/Browser/BudgetsFeatureNavigationTest.php index bf8a958c..510502c8 100644 --- a/tests/Browser/BudgetsFeatureNavigationTest.php +++ b/tests/Browser/BudgetsFeatureNavigationTest.php @@ -3,21 +3,9 @@ use App\Models\Budget; use App\Models\Category; use App\Models\User; -use Laravel\Pennant\Feature; - -test('budgets menu item hidden when feature disabled', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->deactivate('budgets'); - - $page = $this->actingAs($user)->visit('/dashboard'); - - $page->assertDontSee('Budgets') - ->assertNoJavascriptErrors(); -}); test('budgets menu item visible when feature enabled', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/dashboard'); @@ -25,18 +13,8 @@ test('budgets menu item visible when feature enabled', function () { ->assertNoJavascriptErrors(); }); -test('user cannot access budgets page when feature disabled', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->get('/budgets'); - - $response->assertNotFound(); -}); - test('user can navigate to budgets index page', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/budgets'); @@ -47,7 +25,6 @@ test('user can navigate to budgets index page', function () { test('user can view empty budgets list', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/budgets'); @@ -57,7 +34,6 @@ test('user can view empty budgets list', function () { test('user can view budgets list with existing budgets', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -75,7 +51,6 @@ test('user can view budgets list with existing budgets', function () { test('user can open create budget dialog', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); @@ -90,7 +65,6 @@ test('user can open create budget dialog', function () { test('user can view a specific budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -111,7 +85,6 @@ test('user can view a specific budget', function () { test('user can open edit budget dialog', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -131,7 +104,6 @@ test('user can open edit budget dialog', function () { test('user can open delete budget dialog', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -154,8 +126,6 @@ test('user can open delete budget dialog', function () { test('user cannot access another users budget', function () { $user1 = User::factory()->create(['onboarded_at' => now()]); $user2 = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user1)->activate('budgets'); - Feature::for($user2)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user1->id]); $budget = Budget::factory()->create([ @@ -170,7 +140,6 @@ test('user cannot access another users budget', function () { test('budgets navigation works from sidebar', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/dashboard'); @@ -180,7 +149,6 @@ test('budgets navigation works from sidebar', function () { test('budgets page shows correct feature flag state', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $page = $this->actingAs($user)->visit('/budgets'); diff --git a/tests/Feature/BudgetFeatureFlagTest.php b/tests/Feature/BudgetFeatureFlagTest.php deleted file mode 100644 index eb7aaac3..00000000 --- a/tests/Feature/BudgetFeatureFlagTest.php +++ /dev/null @@ -1,114 +0,0 @@ -create(['onboarded_at' => now()]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->get('/budgets'); - - $response->assertNotFound(); -}); - -test('users with budgets feature can access budgets index', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - - Feature::for($user)->activate('budgets'); - - $response = $this->actingAs($user)->get('/budgets'); - - $response->assertOk(); -}); - -test('users without budgets feature get 404 on budgets show', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - $budget = Budget::factory()->create(['user_id' => $user->id]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->get("/budgets/{$budget->id}"); - - $response->assertNotFound(); -}); - -test('users without budgets feature get 404 on budgets store', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - $category = Category::factory()->create(['user_id' => $user->id]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->post('/budgets', [ - 'name' => 'Test Budget', - 'period_type' => 'monthly', - 'period_start_day' => 1, - 'category_id' => $category->id, - 'rollover_type' => 'reset', - 'allocated_amount' => 100000, - ]); - - $response->assertNotFound(); -}); - -test('users without budgets feature get 404 on budgets update', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - $budget = Budget::factory()->create(['user_id' => $user->id]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->patch("/budgets/{$budget->id}", [ - 'name' => 'Updated Budget', - ]); - - $response->assertNotFound(); -}); - -test('users without budgets feature get 404 on budgets destroy', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - $budget = Budget::factory()->create(['user_id' => $user->id]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->delete("/budgets/{$budget->id}"); - - $response->assertNotFound(); -}); - -test('budgets feature flag is shared with frontend when enabled', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - - Feature::for($user)->activate('budgets'); - - $response = $this->actingAs($user)->get('/dashboard'); - - $response->assertOk(); - $response->assertInertia(fn ($page) => $page - ->where('features.budgets', true) - ); -}); - -test('budgets feature flag is shared with frontend when disabled', function () { - $user = User::factory()->create(['onboarded_at' => now()]); - - Feature::for($user)->deactivate('budgets'); - - $response = $this->actingAs($user)->get('/dashboard'); - - $response->assertOk(); - $response->assertInertia(fn ($page) => $page - ->where('features.budgets', false) - ); -}); - -test('guests see budgets feature as false', function () { - $response = $this->get('/'); - - $response->assertOk(); - $response->assertInertia(fn ($page) => $page - ->where('features.budgets', false) - ); -}); diff --git a/tests/Feature/BudgetHistoricalAssignmentTest.php b/tests/Feature/BudgetHistoricalAssignmentTest.php index a005d271..284c690d 100644 --- a/tests/Feature/BudgetHistoricalAssignmentTest.php +++ b/tests/Feature/BudgetHistoricalAssignmentTest.php @@ -7,13 +7,11 @@ use App\Models\Label; use App\Models\Transaction; use App\Models\User; use Illuminate\Support\Facades\Queue; -use Laravel\Pennant\Feature; use function Pest\Laravel\assertDatabaseHas; beforeEach(function () { $this->user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($this->user)->activate('budgets'); }); test('budget creation dispatches the historical assignment job', function () { diff --git a/tests/Feature/BudgetPeriodDateTest.php b/tests/Feature/BudgetPeriodDateTest.php index dbd274ac..a7418268 100644 --- a/tests/Feature/BudgetPeriodDateTest.php +++ b/tests/Feature/BudgetPeriodDateTest.php @@ -5,7 +5,6 @@ use App\Models\Budget; use App\Models\BudgetPeriod; use App\Models\User; use Carbon\Carbon; -use Laravel\Pennant\Feature; test('getCurrentPeriod finds period on its last day regardless of time', function () { Carbon::setTestNow(Carbon::parse('2026-01-31 15:30:00')); @@ -62,7 +61,6 @@ test('budget index loads current period on last day of period', function () { Carbon::setTestNow(Carbon::parse('2026-01-31 18:00:00')); $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->create([ 'user_id' => $user->id, @@ -93,7 +91,6 @@ test('budget show finds current period on last day of period', function () { Carbon::setTestNow(Carbon::parse('2026-01-31 20:00:00')); $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->create([ 'user_id' => $user->id, diff --git a/tests/Feature/BudgetTest.php b/tests/Feature/BudgetTest.php index e7eb6159..ea8f2405 100644 --- a/tests/Feature/BudgetTest.php +++ b/tests/Feature/BudgetTest.php @@ -3,11 +3,9 @@ use App\Models\Budget; use App\Models\Category; use App\Models\User; -use Laravel\Pennant\Feature; test('user can create a budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); @@ -36,7 +34,6 @@ test('user can create a budget', function () { test('user can view their budgets', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->create(['user_id' => $user->id]); @@ -51,7 +48,6 @@ test('user can view their budgets', function () { test('user can view a specific budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); $budget = Budget::factory()->create([ @@ -72,8 +68,6 @@ test('user can view a specific budget', function () { test('user cannot view another users budget', function () { $user1 = User::factory()->create(['onboarded_at' => now()]); $user2 = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user1)->activate('budgets'); - Feature::for($user2)->activate('budgets'); $budget = Budget::factory()->create(['user_id' => $user1->id]); @@ -84,7 +78,6 @@ test('user cannot view another users budget', function () { test('user can update their budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->create(['user_id' => $user->id]); @@ -102,7 +95,6 @@ test('user can update their budget', function () { test('user can delete their budget', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->create(['user_id' => $user->id]); @@ -117,7 +109,6 @@ test('user can delete their budget', function () { test('budget show returns previous period when it exists', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->monthly()->create([ 'user_id' => $user->id, @@ -153,7 +144,6 @@ test('budget show returns previous period when it exists', function () { test('budget show returns null previous period when it is the first period', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $budget = Budget::factory()->monthly()->create([ 'user_id' => $user->id, @@ -180,7 +170,6 @@ test('budget show returns null previous period when it is the first period', fun test('budget period is automatically generated', function () { $user = User::factory()->create(['onboarded_at' => now()]); - Feature::for($user)->activate('budgets'); $category = Category::factory()->create(['user_id' => $user->id]); diff --git a/tests/Feature/TransactionTest.php b/tests/Feature/TransactionTest.php index 9715b00a..e68b94f1 100644 --- a/tests/Feature/TransactionTest.php +++ b/tests/Feature/TransactionTest.php @@ -8,7 +8,6 @@ use App\Models\Category; use App\Models\Label; use App\Models\Transaction; use App\Models\User; -use Laravel\Pennant\Feature; use function Pest\Laravel\actingAs; @@ -613,8 +612,6 @@ test('updating transaction labels via API works correctly', function () { test('when budget with label exists, updating transaction with that label assigns it to budget', function () { $user = User::factory()->onboarded()->create(); - Feature::for($user)->activate('budgets'); - $account = Account::factory()->create(['user_id' => $user->id]); $label = Label::factory()->create(['user_id' => $user->id, 'name' => 'Work']);