AssertIsTypeMethodCallRector

Replaces Assert::isType() calls with type-specific Assert::is*() calls

 use PHPUnit\Framework\TestCase;

 final class SomeClass extends TestCase
 {
     public function testMethod(): void
     {
-        $this->assertThat([], $this->isType('array'));
+        $this->assertThat([], $this->isArray());
     }
 }

Configure your rector.php:

<?php

use Rector\Config\RectorConfig;
use Rector\PHPUnit\PHPUnit120\Rector\Class_\AssertIsTypeMethodCallRector;

return RectorConfig::configure()
    ->withRules([
        AssertIsTypeMethodCallRector::class,
    ]);