1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28:
<?php
namespace Guzzle\Tests\Parsers\UriTemplate;
use Guzzle\Parser\UriTemplate\PeclUriTemplate;
class PeclUriTemplateTest extends AbstractUriTemplateTest
{
protected function setUp()
{
if (!extension_loaded('uri_template')) {
$this->markTestSkipped('uri_template PECL extension must be installed to test PeclUriTemplate');
}
}
public function testExpandsUriTemplates($template, $expansion, $params)
{
$uri = new PeclUriTemplate($template);
$this->assertEquals($expansion, $uri->expand($template, $params));
}
}