From cdf0b9561caa20661a6bcba6cdba1b3968e1e51e Mon Sep 17 00:00:00 2001 From: Jasper Tey Date: Sun, 17 Nov 2024 20:30:54 -0500 Subject: [PATCH] try again --- tests/Command/OptimizeTest.php | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/tests/Command/OptimizeTest.php b/tests/Command/OptimizeTest.php index 862f781..b1e4b5e 100644 --- a/tests/Command/OptimizeTest.php +++ b/tests/Command/OptimizeTest.php @@ -88,20 +88,12 @@ }); describe('laravel optimize', function () { - beforeEach(function () { - $this->artisan('optimize:clear')->assertSuccessful()->execute(); - config()->set('data.structure_caching.enabled', false); - }); - - afterEach(function () { - $this->artisan('optimize:clear')->assertSuccessful()->execute(); - }); - test('optimize will include ddd:optimize', function () { expect(DomainCache::get('domain-providers'))->toBeNull(); expect(DomainCache::get('domain-commands'))->toBeNull(); expect(DomainCache::get('domain-migration-paths'))->toBeNull(); + config()->set('data.structure_caching.enabled', false); $this->artisan('optimize')->assertSuccessful()->execute(); expect(DomainCache::get('domain-providers'))->not->toBeNull(); @@ -112,6 +104,7 @@ }); test('optimize:clear will clear ddd cache', function () { + config()->set('data.structure_caching.enabled', false); $this->artisan('ddd:optimize')->assertSuccessful()->execute(); expect(DomainCache::get('domain-providers'))->not->toBeNull();