File tree 1 file changed +17
-4
lines changed
app/code/Magento/Cms/Test/Unit/Block
1 file changed +17
-4
lines changed Original file line number Diff line number Diff line change @@ -127,9 +127,9 @@ public function testBlockCacheIdentitiesContainExplicitScopeInformation(): void
127
127
$ identities = $ block ->getIdentities ();
128
128
129
129
// Then
130
- $ this ->assertContains ($ this ->getCacheKeyStubById (self ::STUB_CMS_BLOCK_ID ), $ identities );
130
+ $ this ->assertContains ($ this ->getIdentityStubById (self ::STUB_CMS_BLOCK_ID ), $ identities );
131
131
$ this ->assertContains (
132
- $ this ->getCacheKeyStubByIdentifier (self ::STUB_EXISTING_IDENTIFIER , self ::STUB_DEFAULT_STORE ),
132
+ $ this ->getIdentityStubByIdentifier (self ::STUB_EXISTING_IDENTIFIER , self ::STUB_DEFAULT_STORE ),
133
133
$ identities
134
134
);
135
135
}
@@ -195,12 +195,25 @@ private function getPassthroughFilterMock(): Template
195
195
return $ filterMock ;
196
196
}
197
197
198
- private function getCacheKeyStubByIdentifier (string $ identifier , int $ storeId = self ::STUB_DEFAULT_STORE ): string
198
+ /**
199
+ * Returns stub of Identity based on `$identifier` and `$storeId`
200
+ *
201
+ * @param string $identifier
202
+ * @param int $storeId
203
+ * @return string
204
+ */
205
+ private function getIdentityStubByIdentifier (string $ identifier , int $ storeId = self ::STUB_DEFAULT_STORE ): string
199
206
{
200
207
return BlockByIdentifier::CACHE_KEY_PREFIX . '_ ' . $ identifier . '_ ' . $ storeId ;
201
208
}
202
209
203
- private function getCacheKeyStubById (int $ cmsBlockId ): string
210
+ /**
211
+ * Returns stub of Identity based on `$cmsBlockId`
212
+ *
213
+ * @param int $cmsBlockId
214
+ * @return string
215
+ */
216
+ private function getIdentityStubById (int $ cmsBlockId ): string
204
217
{
205
218
return BlockByIdentifier::CACHE_KEY_PREFIX . '_ ' . $ cmsBlockId ;
206
219
}
You can’t perform that action at this time.
0 commit comments