Fix pre-existing PHPStan failures (deprecation issues)
The PHPStan job (`phpstan.neon`, level 3) reports errors that are **unrelated to any current feature work** — they exist on `1.x` independently. CI stays red because of them, masking the real status of feature MRs (e.g. https://git.drupalcode.org/project/gemini_provider/-/work_items/3589183#note_1000755 https://git.drupalcode.org/project/gemini_provider/-/merge_requests/37). ### Steps to reproduce 1. Check out `1.x` (or any feature branch). 2. Run the PHPStan job (or `vendor/bin/phpstan analyse` with the module's `phpstan.neon`). 3. Observe the errors below. ### The errors https://git.drupalcode.org/project/gemini_provider/-/jobs/9036666 **A. `class.notFound` — `src/Plugin/AiProvider/GeminiProvider.php`** `Line 579 Parameter $input of method GeminiProvider::speechToText() has invalid`\ ` type Drupal\ai\OperationType\SpeechToText\SpeechToTextInput. class.notFound`\ `Line 644 Parameter $input of method GeminiProvider::textToImage() has invalid`\ ` type Drupal\ai\OperationType\TextToImage\TextToImageInput. class.notFound`\ `Line 705 Parameter $input of method GeminiProvider::textToSpeech() has invalid`\ ` type Drupal\ai\OperationType\TextToSpeech\TextToSpeechInput. class.notFound` **B. `method.notFound` — `tests/src/Kernel/Plugin/AiProvider/GeminiProviderKernelTest.php`** `Lines 59,70,81,82,83,84,121 Call to undefined method Drupal\ai\Plugin\ProviderProxy::isUsable(). Line 160 Call to undefined method ProviderProxy::setConfiguration(). Line 168 Call to undefined method ProviderProxy::getConfiguration().` **C. `method.deprecated` — `tests/src/Unit/Plugin/AiProvider/GeminiProviderChatTest.php`** `Lines 45,60,72 Call to deprecated method setChatSystemRole() of GeminiProvider: deprecated in ai:1.2.0 and removed from ai:2.0.0. Use setSystemPrompt() in the ChatInput class instead.`
issue