Change method calls from $this->json to $this->postJson, $this->putJson, etc.
-$this->json("POST", "/api/v1/users", $data);
+$this->postJson("/api/v1/users", $data);
Configure your rector.php
:
<?php
use RectorLaravel\Rector\MethodCall\JsonCallToExplicitJsonCallRector;
use Rector\Config\RectorConfig;
return RectorConfig::configure()
->withRules([
JsonCallToExplicitJsonCallRector::class,
]);