Updated tests

This commit is contained in:
Alex Bilbie
2014-01-16 16:51:06 +00:00
parent 36760a07cc
commit add1aa5949
13 changed files with 805 additions and 18 deletions

View File

@ -0,0 +1,24 @@
<?php
namespace LeagueTests\Entities;
use League\OAuth2\Server\Entity\Client;
use \Mockery as M;
class ClientTest extends \PHPUnit_Framework_TestCase
{
public function testSetGet()
{
$server = M::mock('League\OAuth2\Server\AbstractServer');
$client = new Client($server);
$client->setId('foobar');
$client->setSecret('barfoo');
$client->setName('Test Client');
$client->setRedirectUri('http://foo/bar');
$this->assertEquals('foobar', $client->getId());
$this->assertEquals('barfoo', $client->getSecret());
$this->assertEquals('Test Client', $client->getName());
$this->assertEquals('http://foo/bar', $client->getRedirectUri());
}
}