2017-01-09 20:58:15 +00:00
|
|
|
<?php
|
2023-08-18 13:06:30 +00:00
|
|
|
declare(strict_types=1);
|
2017-01-09 20:58:15 +00:00
|
|
|
|
|
|
|
namespace Tests\Skobkin\PointToolsBundle\DTO;
|
|
|
|
|
2023-08-18 13:06:30 +00:00
|
|
|
use App\DTO\TopUserDTO;
|
2017-01-09 20:58:15 +00:00
|
|
|
|
|
|
|
class TopUserTest extends \PHPUnit_Framework_TestCase
|
|
|
|
{
|
|
|
|
public function testCreate()
|
|
|
|
{
|
|
|
|
return new TopUserDTO('testuser', 3);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @depends testCreate
|
|
|
|
*/
|
|
|
|
public function testGetLogin(TopUserDTO $topUser)
|
|
|
|
{
|
2023-08-18 13:06:30 +00:00
|
|
|
$this->assertInternalType('string', $topUser->login);
|
|
|
|
$this->assertEquals('testuser', $topUser->login);
|
2017-01-09 20:58:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @depends testCreate
|
|
|
|
*/
|
|
|
|
public function testGetSubscribersCount(TopUserDTO $topUser)
|
|
|
|
{
|
2023-08-18 13:06:30 +00:00
|
|
|
$this->assertInternalType('int', $topUser->subscribersCount);
|
|
|
|
$this->assertEquals(3, $topUser->subscribersCount);
|
2017-01-09 20:58:15 +00:00
|
|
|
}
|
2023-08-18 13:06:30 +00:00
|
|
|
}
|