Problem/Motivation
In PHPUnit 10, data provider methods that are not declared static
yield deprecation errors in PHPUnit runs like
There were 2 PHPUnit deprecations:
1) Drupal\Tests\Core\Entity\EntityFieldManagerTest::testGetBaseFieldDefinitionsTranslatableEntityTypeDefaultLangcode
Data Provider method Drupal\Tests\Core\Entity\EntityFieldManagerTest::providerTestGetBaseFieldDefinitionsTranslatableEntityTypeDefaultLangcode() is not static
/var/www/html/core/tests/Drupal/Tests/Core/Entity/EntityFieldManagerTest.php:345
2) Drupal\Tests\Core\Entity\EntityFieldManagerTest::testGetBaseFieldDefinitionsTranslatableEntityTypeLangcode
Data Provider method Drupal\Tests\Core\Entity\EntityFieldManagerTest::providerTestGetBaseFieldDefinitionsTranslatableEntityTypeLangcode() is not static
/var/www/html/core/tests/Drupal/Tests/Core/Entity/EntityFieldManagerTest.php:382
Proposed resolution
Declare all data provider methods as static
.