mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-25 18:45:27 -06:00
Fixed all phpstan inspections on tests
This commit is contained in:
@@ -6,7 +6,6 @@ namespace ShlinkioTest\Shlink\Core\Visit\Geolocation;
|
||||
|
||||
use Doctrine\ORM\EntityManager;
|
||||
use Exception;
|
||||
use PHPUnit\Framework\Assert;
|
||||
use PHPUnit\Framework\MockObject\MockObject;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Shlinkio\Shlink\Core\Exception\IpCannotBeLocatedException;
|
||||
@@ -19,10 +18,8 @@ use Shlinkio\Shlink\Core\Visit\Model\Visitor;
|
||||
use Shlinkio\Shlink\Core\Visit\Repository\VisitRepositoryInterface;
|
||||
use Shlinkio\Shlink\IpGeolocation\Model\Location;
|
||||
|
||||
use function array_shift;
|
||||
use function count;
|
||||
use function floor;
|
||||
use function func_get_args;
|
||||
use function Functional\map;
|
||||
use function range;
|
||||
use function sprintf;
|
||||
@@ -72,10 +69,6 @@ class VisitLocatorTest extends TestCase
|
||||
|
||||
public function onVisitLocated(VisitLocation $visitLocation, Visit $visit): void
|
||||
{
|
||||
$args = func_get_args();
|
||||
|
||||
Assert::assertInstanceOf(VisitLocation::class, array_shift($args));
|
||||
Assert::assertInstanceOf(Visit::class, array_shift($args));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -45,6 +45,8 @@ class NonOrphanVisitsPaginatorAdapterTest extends TestCase
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int<0, max> $limit
|
||||
* @param int<0, max> $offset
|
||||
* @test
|
||||
* @dataProvider provideLimitAndOffset
|
||||
*/
|
||||
|
||||
@@ -41,6 +41,8 @@ class OrphanVisitsPaginatorAdapterTest extends TestCase
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int<0, max> $limit
|
||||
* @param int<0, max> $offset
|
||||
* @test
|
||||
* @dataProvider provideLimitAndOffset
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user