From 9ad115307de212ca05778ac42ab3e3f801a4717a Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 17:44:25 +0100 Subject: [PATCH 01/10] Updating README --- README.md | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 6feb049b..3b228cba 100644 --- a/README.md +++ b/README.md @@ -68,6 +68,14 @@ Or if you prefer requests to happen securely: $client = new \Tmdb\Client($token, null, true); ``` +If you want to add some caching capabilities ( currently an implementation of the `GuzzleCachePlugin` ); + +```php +$client->setCaching(true, '/tmp/php-tmdb-api'; +``` + +_This relies on max-age headers being sent back from TMDB, see the [documentation of the CachePlugin](http://guzzle.readthedocs.org/en/latest/plugins/cache-plugin.html)._ + Then we do some work on it: ```php @@ -98,6 +106,14 @@ Or if you prefer requests to happen securely: $client = new \Tmdb\Client($token, null, true); ``` +If you want to add some caching capabilities ( currently an implementation of the `GuzzleCachePlugin` ); + +```php +$client->setCaching(true, '/tmp/php-tmdb-api'; +``` + +_This relies on max-age headers being sent back from TMDB, see the [documentation of the CachePlugin](http://guzzle.readthedocs.org/en/latest/plugins/cache-plugin.html)._ + Then you pass this client onto one of the many repositories and do some work on it. ```php @@ -148,5 +164,14 @@ $backdrop = $movie ->filterBackdrops() ; ``` +_And there are more Collections which provide filters, but you will find those out along the way._ + +Some other useful hints +----------------------- + +__There are 2 types of "main" collections, the `GenericCollection` and the `ResultCollection`.__ + +The `GenericCollection holds any collection of objects ( e.g. an collection of movies ). -__And there are more Collections which provide filters, but you will find those out along the way.__ +The `ResultCollection` is an extension of the `GenericCollection`, and inherits response parameters _( page, total_pages, total_results )_ from an resultset, +this can be used to create paginators. \ No newline at end of file From 728e3b372dcca5637df74a060813c7383bae62a5 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 17:59:08 +0100 Subject: [PATCH 02/10] Adding BackoffRetryPlugin from Guzzle. --- lib/Tmdb/Client.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/Tmdb/Client.php b/lib/Tmdb/Client.php index 0d4c2a74..4e109603 100644 --- a/lib/Tmdb/Client.php +++ b/lib/Tmdb/Client.php @@ -17,6 +17,7 @@ use Guzzle\Common\HasDispatcherInterface; use Guzzle\Http\Client as GuzzleClient; use Guzzle\Http\ClientInterface; +use Guzzle\Plugin\Backoff\BackoffPlugin; use Guzzle\Plugin\Cache\CachePlugin; use Guzzle\Plugin\Cache\DefaultCacheStorage; use Tmdb\HttpClient\HttpClient; @@ -118,6 +119,9 @@ private function constructHttpClient(ClientInterface $httpClient = null) $acceptJsonHeaderPlugin = new AcceptJsonHeaderPlugin(); $httpClient->addSubscriber($acceptJsonHeaderPlugin); + $backoffPlugin = BackoffPlugin::getExponentialBackoff(5); + $httpClient->addSubscriber($backoffPlugin); + if ($this->getToken() instanceof ApiToken) { $apiTokenPlugin = new ApiTokenPlugin($this->getToken()); $httpClient->addSubscriber($apiTokenPlugin); From 857fde8bbd84c91a0ca1f2b4db85cbe1f851f2c0 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 20:20:45 +0100 Subject: [PATCH 03/10] Adding logging functionality, requires monolog to be installed. --- README.md | 12 ++++ composer.json | 6 +- examples/logging.php | 22 +++++++ lib/Tmdb/Client.php | 111 ++++++++++++++++++++++++++++++++- test/Tmdb/Tests/ClientTest.php | 20 ++++++ 5 files changed, 168 insertions(+), 3 deletions(-) create mode 100644 examples/logging.php diff --git a/README.md b/README.md index 3b228cba..70d00575 100644 --- a/README.md +++ b/README.md @@ -76,6 +76,12 @@ $client->setCaching(true, '/tmp/php-tmdb-api'; _This relies on max-age headers being sent back from TMDB, see the [documentation of the CachePlugin](http://guzzle.readthedocs.org/en/latest/plugins/cache-plugin.html)._ +If you want to add some logging capabilities ( currently an implementation of the `GuzzleLogPlugin`, requires `monolog/monolog`); + +```php +$client->setLogging(true, '/tmp/php-tmdb-api.log'; +``` + Then we do some work on it: ```php @@ -114,6 +120,12 @@ $client->setCaching(true, '/tmp/php-tmdb-api'; _This relies on max-age headers being sent back from TMDB, see the [documentation of the CachePlugin](http://guzzle.readthedocs.org/en/latest/plugins/cache-plugin.html)._ +If you want to add some logging capabilities ( currently an implementation of the `GuzzleLogPlugin`, requires `monolog/monolog`); + +```php +$client->setLogging(true, '/tmp/php-tmdb-api.log'; +``` + Then you pass this client onto one of the many repositories and do some work on it. ```php diff --git a/composer.json b/composer.json index ff3b1a87..ccf4814d 100644 --- a/composer.json +++ b/composer.json @@ -19,10 +19,12 @@ }, "require-dev": { "phpunit/phpunit": ">=3.7", - "doctrine/cache": ">=1.3.0" + "doctrine/cache": ">=1.3.0", + "monolog/monolog": ">=1.7.0" }, "suggest": { - "doctrine/cache": "This library is required if you want to make use of caching features." + "doctrine/cache": "This library is required if you want to make use of caching features.", + "monolog/monolog": "This library is required if you want to make use of logging features." }, "autoload": { "psr-0": { "Tmdb\\": "lib/" } diff --git a/examples/logging.php b/examples/logging.php new file mode 100644 index 00000000..71a62f4b --- /dev/null +++ b/examples/logging.php @@ -0,0 +1,22 @@ + + * @copyright (c) 2013, Michael Roterman + * @version 0.0.1 + */ +require_once '../vendor/autoload.php'; +require_once '../apikey.php'; + +$token = new \Tmdb\ApiToken(TMDB_API_KEY); +$client = new \Tmdb\Client($token); + +$client->setLogging(true, '/www/dev/php-tmdb-api/api.log'); + +$repository = new \Tmdb\Repository\MovieRepository($client); +$movie = $repository->load(19995); diff --git a/lib/Tmdb/Client.php b/lib/Tmdb/Client.php index 4e109603..93b0ec91 100644 --- a/lib/Tmdb/Client.php +++ b/lib/Tmdb/Client.php @@ -17,9 +17,12 @@ use Guzzle\Common\HasDispatcherInterface; use Guzzle\Http\Client as GuzzleClient; use Guzzle\Http\ClientInterface; +use Guzzle\Log\MessageFormatter; +use Guzzle\Log\PsrLogAdapter; use Guzzle\Plugin\Backoff\BackoffPlugin; use Guzzle\Plugin\Cache\CachePlugin; use Guzzle\Plugin\Cache\DefaultCacheStorage; +use Guzzle\Plugin\Log\LogPlugin; use Tmdb\HttpClient\HttpClient; use Tmdb\HttpClient\HttpClientInterface; use Tmdb\ApiToken as Token; @@ -76,6 +79,25 @@ class Client */ private $httpClient; + /** + * @var \Psr\Log\LoggerInterface + */ + private $logger; + + /** + * Holds the log path + * + * @var string + */ + private $logPath; + + /** + * Enable logging? + * + * @var bool + */ + private $logEnabled = false; + /** * Stores the cache path * @@ -148,6 +170,35 @@ private function constructHttpClient(ClientInterface $httpClient = null) $httpClient->addSubscriber($cachePlugin); } + if ($this->logEnabled && !empty($this->logPath)) { + if (empty($this->logger) && !class_exists('\Monolog\Logger')) { + /** @codeCoverageIgnoreStart */ + throw new RuntimeException( + 'Could not find any logger set and the monolog logger library was not found + to provide a default, you have to set a custom logger on the client or + have you forgot adding monolog to your composer.json?' + ); + /** @codeCoverageIgnoreEnd */ + } else { + $this->logger = new \Monolog\Logger('php-tmdb-api'); + $this->logger->pushHandler( + new \Monolog\Handler\StreamHandler( + $this->logPath, + \Monolog\Logger::DEBUG + ) + ); + } + + if ($this->logger instanceof \Psr\Log\LoggerInterface) { + $logPlugin = new LogPlugin( + new PsrLogAdapter($this->logger), + MessageFormatter::SHORT_FORMAT + ); + + $httpClient->addSubscriber($logPlugin); + } + } + if ($this->getSessionToken() instanceof SessionToken) { $sessionTokenPlugin = new SessionTokenPlugin($this->getSessionToken()); $httpClient->addSubscriber($sessionTokenPlugin); @@ -437,7 +488,7 @@ public function getCacheEnabled() /** * Set cache path * - * You could simply pass an empty string to let the sys_get_temp_dir be used + * Leaving the second argument out will use sys_get_temp_dir() * * @param boolean $enabled * @param string $path @@ -464,4 +515,62 @@ public function getCachePath() { return $this->cachePath; } + + /** + * @param \Psr\Log\LoggerInterface $logger + * @return $this + */ + public function setLogger($logger) + { + $this->logger = $logger; + + return $this; + } + + /** + * @return \Psr\Log\LoggerInterface + */ + public function getLogger() + { + return $this->logger; + } + + /** + * @return boolean + */ + public function getLogEnabled() + { + return $this->logEnabled; + } + + /** + * Set log path + * + * Leaving the second argument out will use sys_get_temp_dir() + * + * @param boolean $enabled + * @param string $path + * @return $this + */ + public function setLogging($enabled = true, $path = null) + { + $this->logEnabled = $enabled; + $this->logPath = (null === $path) ? + sys_get_temp_dir() . '/php-tmdb-api.log' : + $path + ; + + // @todo doesn't cover a custom client, would require un-registering all known plugins + $this->constructHttpClient(); + + return $this; + } + + /** + * @return string + */ + public function getLogPath() + { + return $this->logPath; + } } diff --git a/test/Tmdb/Tests/ClientTest.php b/test/Tmdb/Tests/ClientTest.php index 24044844..3827c1d4 100644 --- a/test/Tmdb/Tests/ClientTest.php +++ b/test/Tmdb/Tests/ClientTest.php @@ -99,6 +99,26 @@ public function shouldAddCachePluginWhenEnabled() )); } + /** + * @test + */ + public function shouldAddLoggingPluginWhenEnabled() + { + $token = new \Tmdb\ApiToken(self::API_TOKEN); + $client = new \Tmdb\Client($token); + $client->setLogging(true, '/tmp/php-tmdb-api.log'); + + $listeners = $client->getHttpClient() + ->getClient() + ->getEventDispatcher() + ->getListeners(); + + $this->assertEquals(true, $this->isListenerRegistered( + $listeners, + 'Guzzle\Plugin\Log\LogPlugin' + )); + } + /** * Find an plugin in an listeners array * From 8ebbbed0fdb2d925f276a1df9bc7af7e5121c806 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 20:24:00 +0100 Subject: [PATCH 04/10] Fixing some issues --- lib/Tmdb/Client.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Tmdb/Client.php b/lib/Tmdb/Client.php index 93b0ec91..83545a3f 100644 --- a/lib/Tmdb/Client.php +++ b/lib/Tmdb/Client.php @@ -153,7 +153,8 @@ private function constructHttpClient(ClientInterface $httpClient = null) if (!class_exists('Doctrine\Common\Cache\FilesystemCache')) { /** @codeCoverageIgnoreStart */ throw new RuntimeException( - 'Could not find the doctrine cache library, have you added doctrone-cache to your composer.json?' + 'Could not find the doctrine cache library, + have you added doctrine-cache to your composer.json?' ); /** @codeCoverageIgnoreEnd */ } From bc8be43f71c3c9bdacdcc7a9e4815de40eafa04c Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 22:08:57 +0100 Subject: [PATCH 05/10] Small issues / improvements. --- lib/Tmdb/ApiToken.php | 8 +++++++- lib/Tmdb/Client.php | 12 ++++++------ test/Tmdb/Tests/ApiTokenTest.php | 10 ++++++++++ test/Tmdb/Tests/ClientTest.php | 26 ++++++++++++++++++++++++++ 4 files changed, 49 insertions(+), 7 deletions(-) diff --git a/lib/Tmdb/ApiToken.php b/lib/Tmdb/ApiToken.php index 06e30938..c79e4760 100644 --- a/lib/Tmdb/ApiToken.php +++ b/lib/Tmdb/ApiToken.php @@ -11,6 +11,7 @@ * @version 0.0.1 */ namespace Tmdb; +use Tmdb\Exception\RuntimeException; /** * Class ApiToken @@ -31,11 +32,16 @@ public function __construct($api_token = null) } /** - * @param null $apiToken + * @param string $apiToken + * @throws RuntimeException * @return $this */ public function setToken($apiToken) { + if (!is_string($apiToken)) { + throw new RuntimeException('The Apitoken must be set.'); + } + $this->apiToken = $apiToken; return $this; diff --git a/lib/Tmdb/Client.php b/lib/Tmdb/Client.php index 83545a3f..c0afc7ae 100644 --- a/lib/Tmdb/Client.php +++ b/lib/Tmdb/Client.php @@ -151,12 +151,12 @@ private function constructHttpClient(ClientInterface $httpClient = null) if ($this->cacheEnabled && !empty($this->cachePath)) { if (!class_exists('Doctrine\Common\Cache\FilesystemCache')) { - /** @codeCoverageIgnoreStart */ + //@codeCoverageIgnoreStart throw new RuntimeException( 'Could not find the doctrine cache library, have you added doctrine-cache to your composer.json?' ); - /** @codeCoverageIgnoreEnd */ + //@codeCoverageIgnoreEnd } $cachePlugin = new CachePlugin(array( @@ -173,16 +173,16 @@ private function constructHttpClient(ClientInterface $httpClient = null) if ($this->logEnabled && !empty($this->logPath)) { if (empty($this->logger) && !class_exists('\Monolog\Logger')) { - /** @codeCoverageIgnoreStart */ + //@codeCoverageIgnoreStart throw new RuntimeException( 'Could not find any logger set and the monolog logger library was not found to provide a default, you have to set a custom logger on the client or have you forgot adding monolog to your composer.json?' ); - /** @codeCoverageIgnoreEnd */ + //@codeCoverageIgnoreEnd } else { - $this->logger = new \Monolog\Logger('php-tmdb-api'); - $this->logger->pushHandler( + $this->setLogger(new \Monolog\Logger('php-tmdb-api')); + $this->getLogger()->pushHandler( new \Monolog\Handler\StreamHandler( $this->logPath, \Monolog\Logger::DEBUG diff --git a/test/Tmdb/Tests/ApiTokenTest.php b/test/Tmdb/Tests/ApiTokenTest.php index 5949e173..ff7e78bd 100644 --- a/test/Tmdb/Tests/ApiTokenTest.php +++ b/test/Tmdb/Tests/ApiTokenTest.php @@ -26,4 +26,14 @@ public function testSetGet() $this->assertEquals(self::API_TOKEN, $token->getToken()); } + + /** + * @expectedException Tmdb\Exception\RuntimeException + * @test + */ + public function testThrowsErrorOnEmptyApiToken() + { + $token = new \Tmdb\ApiToken(); + $token->setToken(null); + } } diff --git a/test/Tmdb/Tests/ClientTest.php b/test/Tmdb/Tests/ClientTest.php index 3827c1d4..3c030fed 100644 --- a/test/Tmdb/Tests/ClientTest.php +++ b/test/Tmdb/Tests/ClientTest.php @@ -146,4 +146,30 @@ private function isListenerRegistered($listeners, $class) return false; } + + /** + * @test + */ + public function shouldBeAbleSetCache() + { + $path = '/tmp/php-tmdb-api'; + + $this->client->setCaching(true, $path); + + $this->assertEquals(true, $this->client->getCacheEnabled()); + $this->assertEquals($path, $this->client->getCachePath()); + } + + /** + * @test + */ + public function shouldBeAbleSetLogging() + { + $path = '/tmp/php-tmdb-api.log'; + + $this->client->setLogging(true, $path); + + $this->assertEquals(true, $this->client->getLogEnabled()); + $this->assertEquals($path, $this->client->getLogPath()); + } } From c6ec37252b5788187ee12950adf66c329a5d4f90 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 22:37:20 +0100 Subject: [PATCH 06/10] Fixing unit tests of Network --- lib/Tmdb/Api/Authentication.php | 4 +++ lib/Tmdb/Model/Network.php | 14 ++++++++++ test/Tmdb/Tests/Api/PeopleTest.php | 13 ++++++++++ test/Tmdb/Tests/Model/NetworkTest.php | 37 +++++++++++++++++++++++++++ 4 files changed, 68 insertions(+) create mode 100644 test/Tmdb/Tests/Model/NetworkTest.php diff --git a/lib/Tmdb/Api/Authentication.php b/lib/Tmdb/Api/Authentication.php index a28862c9..58ad244f 100644 --- a/lib/Tmdb/Api/Authentication.php +++ b/lib/Tmdb/Api/Authentication.php @@ -44,11 +44,13 @@ public function getNewToken() */ public function authenticateRequestToken($token) { + //@codeCoverageIgnoreStart header(sprintf( 'Location: %s/%s', self::REQUEST_TOKEN_URI, $token )); + //@codeCoverageIgnoreEnd } /** @@ -63,10 +65,12 @@ public function getNewSession($requestToken) { try { return $this->get('authentication/session/new', array('request_token' => $requestToken)); + //@codeCoverageIgnoreStart } catch (\Exception $e) { if ($e->getCode() == 401) { throw new UnauthorizedRequestTokenException("The request token has not been validated yet."); } + //@codeCoverageIgnoreEnd } } diff --git a/lib/Tmdb/Model/Network.php b/lib/Tmdb/Model/Network.php index f7174d3e..d71d64a9 100644 --- a/lib/Tmdb/Model/Network.php +++ b/lib/Tmdb/Model/Network.php @@ -18,9 +18,23 @@ */ class Network extends AbstractModel { + /** + * @var integer + */ private $id; + + /** + * @var string + */ private $name; + /** + * Properties that are available in the API + * + * These properties are hydrated by the ObjectHydrator, all the other properties are handled by the factory. + * + * @var array + */ public static $properties = array( 'id', 'name', diff --git a/test/Tmdb/Tests/Api/PeopleTest.php b/test/Tmdb/Tests/Api/PeopleTest.php index 257c5e9d..ad16fe42 100644 --- a/test/Tmdb/Tests/Api/PeopleTest.php +++ b/test/Tmdb/Tests/Api/PeopleTest.php @@ -94,6 +94,19 @@ public function shouldGetChanges() $api->getChanges(self::PERSON_ID); } + /** + * @test + */ + public function shouldGetExternalIds() + { + $api = $this->getApiMock(); + $api->expects($this->once()) + ->method('get') + ->with('person/' . self::PERSON_ID . '/external_ids'); + + $api->getExternalIds(self::PERSON_ID); + } + /** * @test */ diff --git a/test/Tmdb/Tests/Model/NetworkTest.php b/test/Tmdb/Tests/Model/NetworkTest.php new file mode 100644 index 00000000..ac894cc1 --- /dev/null +++ b/test/Tmdb/Tests/Model/NetworkTest.php @@ -0,0 +1,37 @@ + + * @copyright (c) 2013, Michael Roterman + * @version 0.0.1 + */ +namespace Tmdb\Tests\Model; + +use Tmdb\Common\ObjectHydrator; +use Tmdb\Model\Network; + +class NetworkTest extends TestCase +{ + /** + * @test + */ + public function shouldBeFunctional() + { + $data = array( + 'id' => 1, + 'name' => 'name', + ); + + $hydrator = new ObjectHydrator(); + + $object = $hydrator->hydrate(new Network(), $data); + + $this->assertEquals(1, $object->getId()); + $this->assertEquals('name', $object->getName()); + } +} From a480e98e7a43e239e211cec3cccdf052c11dec9b Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 22:39:23 +0100 Subject: [PATCH 07/10] Removing deprecated Tv\Network class, TMDB moved this up to a top resident. --- lib/Tmdb/Model/Tv/Network.php | 82 ------------------------ test/Tmdb/Tests/Model/Tv/NetworkTest.php | 38 ----------- 2 files changed, 120 deletions(-) delete mode 100644 lib/Tmdb/Model/Tv/Network.php delete mode 100644 test/Tmdb/Tests/Model/Tv/NetworkTest.php diff --git a/lib/Tmdb/Model/Tv/Network.php b/lib/Tmdb/Model/Tv/Network.php deleted file mode 100644 index 366f9003..00000000 --- a/lib/Tmdb/Model/Tv/Network.php +++ /dev/null @@ -1,82 +0,0 @@ - - * @copyright (c) 2013, Michael Roterman - * @version 0.0.1 - */ -namespace Tmdb\Model\Tv; - -use Tmdb\Model\AbstractModel; - -/** - * Class Network - * @package Tmdb\Model\Tv - */ -class Network extends AbstractModel -{ - /** - * @var integer - */ - private $id; - - /** - * @var string - */ - private $name; - - /** - * Properties that are available in the API - * - * These properties are hydrated by the ObjectHydrator, all the other properties are handled by the factory. - * - * @var array - */ - public static $properties = array( - 'id', - 'name', - ); - - /** - * @param int $id - * @return $this - */ - public function setId($id) - { - $this->id = (int) $id; - - return $this; - } - - /** - * @return int - */ - public function getId() - { - return $this->id; - } - - /** - * @param string $name - * @return $this - */ - public function setName($name) - { - $this->name = $name; - - return $this; - } - - /** - * @return string - */ - public function getName() - { - return $this->name; - } -} diff --git a/test/Tmdb/Tests/Model/Tv/NetworkTest.php b/test/Tmdb/Tests/Model/Tv/NetworkTest.php deleted file mode 100644 index 0a7c3c1f..00000000 --- a/test/Tmdb/Tests/Model/Tv/NetworkTest.php +++ /dev/null @@ -1,38 +0,0 @@ - - * @copyright (c) 2013, Michael Roterman - * @version 0.0.1 - */ -namespace Tmdb\Tests\Model\Tv; - -use Tmdb\Common\ObjectHydrator; -use Tmdb\Model\Tv\Network; -use Tmdb\Tests\Model\TestCase; - -class NetworkTest extends TestCase -{ - /** - * @test - */ - public function shouldBeFunctional() - { - $data = array( - 'id' => 1, - 'name' => 'name', - ); - - $hydrator = new ObjectHydrator(); - - $object = $hydrator->hydrate(new Network(), $data); - - $this->assertEquals(1, $object->getId()); - $this->assertEquals('name', $object->getName()); - } -} From d5986f75b456861f6dc0a12dd7af4215b52eb143 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 22:51:30 +0100 Subject: [PATCH 08/10] Fix references --- lib/Tmdb/Model/Tv.php | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/Tmdb/Model/Tv.php b/lib/Tmdb/Model/Tv.php index 95ddc93d..6a5cac1b 100644 --- a/lib/Tmdb/Model/Tv.php +++ b/lib/Tmdb/Model/Tv.php @@ -19,7 +19,6 @@ use Tmdb\Model\Image\BackdropImage; use Tmdb\Model\Image\PosterImage; use Tmdb\Model\Common\ExternalIds; -use Tmdb\Model\Tv\Network; /** * Class Tv From 158dbc805639aca4e402ee82fac56e91e2a264a7 Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 23:14:19 +0100 Subject: [PATCH 09/10] Updating travis ci for php 5.6 and hhvm. --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 4eb9321d..464a8999 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,8 @@ php: - 5.3 - 5.4 - 5.5 + - 5.6 + - hhvm before_script: - composer --prefer-source install From 57c7b7b3864ba048ca3bf75bce6683732803d4ff Mon Sep 17 00:00:00 2001 From: Michael Roterman Date: Sun, 2 Mar 2014 23:33:29 +0100 Subject: [PATCH 10/10] Updating README --- README.md | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 70d00575..fa57fe0a 100644 --- a/README.md +++ b/README.md @@ -14,11 +14,18 @@ Stable [![Latest Stable Version](https://poser.pugx.org/wtfzdotnet/php-tmdb-api/v/stable.png)](https://packagist.org/packages/wtfzdotnet/php-tmdb-api) [![Dependency Status](https://www.versioneye.com/user/projects/530a7514ec137594df000010/badge.png)](https://www.versioneye.com/user/projects/530a7514ec137594df000010) +[![Latest Unstable Version](https://poser.pugx.org/wtfzdotnet/php-tmdb-api/v/unstable.png)](https://packagist.org/packages/wtfzdotnet/php-tmdb-api) -Unstable ----------------- +First stable version is just around the corner, currently making a last thorough review and improving test coverage. -[![Latest Unstable Version](https://poser.pugx.org/wtfzdotnet/php-tmdb-api/v/unstable.png)](https://packagist.org/packages/wtfzdotnet/php-tmdb-api) +Currently unit tests are run on travis, with the following versions: + +- 5.3.3 +- 5.3 +- 5.4 +- 5.5 +- 5.6 +- hhvm _( we do not officially support this, however tests indicate it should be functional. )_ Help & Donate --------------