2024-02-02 14:53:38 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
declare(strict_types=1);
|
2024-02-02 11:04:31 +00:00
|
|
|
|
|
|
|
namespace DNW\Skills\Tests;
|
|
|
|
|
|
|
|
use DNW\Skills\Player;
|
|
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
|
|
|
|
class PlayerTest extends TestCase
|
|
|
|
{
|
2024-03-01 12:56:55 +00:00
|
|
|
public function testPlayerObjectGetterSetter(): void
|
2024-02-02 11:04:31 +00:00
|
|
|
{
|
|
|
|
$p = new Player('dummy', 0.1, 0.2);
|
|
|
|
$this->assertEquals('dummy', (string)$p);
|
2024-03-01 12:56:55 +00:00
|
|
|
$this->assertEquals('dummy', $p->getId());
|
2024-02-02 11:04:31 +00:00
|
|
|
$this->assertEquals(0.1, $p->getPartialPlayPercentage());
|
|
|
|
$this->assertEquals(0.2, $p->getPartialUpdatePercentage());
|
|
|
|
}
|
|
|
|
}
|