Files
cloudflare-php/tests/Configurations/PageRulesTargetTest.php
2017-09-20 11:52:33 +01:00

22 lines
544 B
PHP

<?php
/**
* Created by PhpStorm.
* User: junade
* Date: 19/09/2017
* Time: 18:41
*/
use Cloudflare\API\Configurations\PageRulesTargets;
class PageRulesTargetTest extends PHPUnit_Framework_TestCase
{
public function testGetArray() {
$targets = new PageRulesTargets('junade.com/*');
$array = $targets->getArray();
$this->assertEquals(1, sizeof($array));
$this->assertEquals("junade.com/*", $array[0]->constraint->value);
$this->assertEquals("matches", $array[0]->constraint->operator);
}
}