Issue #3163687 by shetpooja04, snehalgaikwad, longwave: Unused variable $id in field module, BulkDeleteTest.php

(cherry picked from commit 5b454e760f)
merge-requests/64/head
Alex Pott 2020-08-07 23:13:04 +01:00
parent 266b710024
commit cf9848243c
No known key found for this signature in database
GPG Key ID: 31905460D4A69276
1 changed files with 3 additions and 12 deletions

View File

@ -344,10 +344,7 @@ class BulkDeleteTest extends FieldKernelTestBase {
// bundle.
$actual_hooks = field_test_memorize();
$hooks = [];
$entities = $this->entitiesByBundles[$bundle];
foreach ($entities as $id => $entity) {
$hooks['field_test_field_delete'][] = $entity;
}
$hooks['field_test_field_delete'] = $this->entitiesByBundles[$bundle];
$this->checkHooksInvocations($hooks, $actual_hooks);
// The field still exists, deleted.
@ -395,10 +392,7 @@ class BulkDeleteTest extends FieldKernelTestBase {
// bundle.
$actual_hooks = field_test_memorize();
$hooks = [];
$entities = $this->entitiesByBundles[$bundle];
foreach ($entities as $id => $entity) {
$hooks['field_test_field_delete'][] = $entity;
}
$hooks['field_test_field_delete'] = $this->entitiesByBundles[$bundle];
$this->checkHooksInvocations($hooks, $actual_hooks);
// The field still exists, deleted.
@ -430,10 +424,7 @@ class BulkDeleteTest extends FieldKernelTestBase {
// Check hooks invocations (same as above, for the 2nd bundle).
$actual_hooks = field_test_memorize();
$hooks = [];
$entities = $this->entitiesByBundles[$bundle];
foreach ($entities as $id => $entity) {
$hooks['field_test_field_delete'][] = $entity;
}
$hooks['field_test_field_delete'] = $this->entitiesByBundles[$bundle];
$this->checkHooksInvocations($hooks, $actual_hooks);
// The field and the storage still exist, deleted.