php-ml/tests/Phpml/Dataset/Demo/GlassTest.php
2016-04-09 15:46:54 +02:00

23 lines
496 B
PHP

<?php
declare (strict_types = 1);
namespace tests\Phpml\Dataset\Demo;
use Phpml\Dataset\Demo\Glass;
class GlassTest extends \PHPUnit_Framework_TestCase
{
public function testLoadingWineDataset()
{
$iris = new Glass();
// whole dataset
$this->assertEquals(214, count($iris->getSamples()));
$this->assertEquals(214, count($iris->getLabels()));
// one sample features count
$this->assertEquals(9, count($iris->getSamples()[0]));
}
}