From a70b5a9d8308b86b44060d9049095995b4a08118 Mon Sep 17 00:00:00 2001 From: luanfreitasdev Date: Wed, 6 Dec 2023 15:45:19 -0300 Subject: [PATCH] wip --- tests/Feature/SetUpTest.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/tests/Feature/SetUpTest.php b/tests/Feature/SetUpTest.php index 29f16074..96e65dd1 100644 --- a/tests/Feature/SetUpTest.php +++ b/tests/Feature/SetUpTest.php @@ -50,7 +50,7 @@ ->ttl->toBe(300); $tag = 'test-powergrid-dishes-default'; - $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; $tags = \Illuminate\Support\Facades\Cache::tags($tag); @@ -64,10 +64,10 @@ $storage = Livewire\invade($tags->getStore())->storage; expect(json_encode($storage)) - ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}-{\"sortArray\":[]}'); + ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}'); $component->set('search', 'New search'); - $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; /** @var LengthAwarePaginator $items */ $items = $tags->get($cacheKeySearch); @@ -98,7 +98,7 @@ ->ttl->toBe(360); $tag = 'powergrid-dishes-default'; - $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; $tags = \Illuminate\Support\Facades\Cache::tags($tag); @@ -112,10 +112,10 @@ $storage = Livewire\invade($tags->getStore())->storage; expect(json_encode($storage)) - ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}-{\"sortArray\":[]}'); + ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}'); $component->set('search', 'New search'); - $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; /** @var LengthAwarePaginator $items */ $items = $tags->get($cacheKeySearch); @@ -147,7 +147,7 @@ ->ttl->toBe(360); $tag = 'my-custom-tag'; - $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKey = '{"page":1}-{"perPage":15}-{"search":""}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; $tags = \Illuminate\Support\Facades\Cache::tags($tag); @@ -161,10 +161,10 @@ $storage = Livewire\invade($tags->getStore())->storage; expect(json_encode($storage)) - ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}-{\"sortArray\":[]}'); + ->toContain('{\"page\":1}-{\"perPage\":15}-{\"search\":\"\"}-{\"sortDirection\":\"asc\"}-{\"sortField\":\"id\"}-{\"filters\":[]}'); $component->set('search', 'New search'); - $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}-{"sortArray":[]}'; + $cacheKeySearch = '{"page":1}-{"perPage":15}-{"search":"New search"}-{"sortDirection":"asc"}-{"sortField":"id"}-{"filters":[]}'; /** @var LengthAwarePaginator $items */ $items = $tags->get($cacheKeySearch);