Update headers and namespaces

This commit is contained in:
Timothy Warren 2016-10-20 22:32:17 -04:00
parent 5e2a68dc84
commit 27f66cfea3
29 changed files with 55 additions and 71 deletions

View File

@ -1,6 +0,0 @@
sonar.projectKey=animeclient
sonar.projectName=Anime Client
sonar.projectVersion=3.0.0
sonar.sources=src
sonar.php.coverage.reportPath=build/logs/clover.xml
sonar.php.tests.reportPath=build/logs/junit.xml

View File

@ -16,8 +16,8 @@
namespace Aviat\AnimeClient\Auth; namespace Aviat\AnimeClient\Auth;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\AnimeClient; use Aviat\AnimeClient\AnimeClient;
use Aviat\Ion\Di\ContainerInterface;
/** /**
* Hummingbird API Authentication * Hummingbird API Authentication

View File

@ -17,17 +17,15 @@
namespace Aviat\AnimeClient\Command; namespace Aviat\AnimeClient\Command;
use Aura\Session\SessionFactory; use Aura\Session\SessionFactory;
use ConsoleKit\Command;
use ConsoleKit\Widgets\Box;
use Aviat\Ion\Config;
use Aviat\Ion\Di\Container;
use Aviat\Ion\Cache\CacheManager;
use Aviat\AnimeClient\AnimeClient; use Aviat\AnimeClient\AnimeClient;
use Aviat\AnimeClient\Auth\HummingbirdAuth; use Aviat\AnimeClient\Auth\HummingbirdAuth;
use Aviat\AnimeClient\Model; use Aviat\AnimeClient\Model;
use Aviat\AnimeClient\Util; use Aviat\AnimeClient\Util;
use Aviat\Ion\Cache\CacheManager;
use Aviat\Ion\Config;
use Aviat\Ion\Di\Container;
use ConsoleKit\Command;
use ConsoleKit\Widgets\Box;
/** /**
* Base class for console command setup * Base class for console command setup

View File

@ -17,6 +17,7 @@
namespace Aviat\AnimeClient\Command; namespace Aviat\AnimeClient\Command;
use Aviat\AnimeClient\Util; use Aviat\AnimeClient\Util;
/** /**
* Generates thumbnail image cache so that cover images load faster * Generates thumbnail image cache so that cover images load faster
*/ */

View File

@ -16,8 +16,14 @@
namespace Aviat\AnimeClient; namespace Aviat\AnimeClient;
use Aviat\Ion\Di\{ContainerAware, ContainerInterface}; use Aviat\Ion\Di\
use Aviat\Ion\View\{HtmlView, HttpView, JsonView}; {
ContainerAware, ContainerInterface
};
use Aviat\Ion\View\
{
HtmlView, HttpView, JsonView
};
use InvalidArgumentException; use InvalidArgumentException;
/** /**

View File

@ -16,10 +16,10 @@
namespace Aviat\AnimeClient\Controller; namespace Aviat\AnimeClient\Controller;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\Controller as BaseController; use Aviat\AnimeClient\Controller as BaseController;
use Aviat\AnimeClient\Hummingbird\Enum\AnimeWatchingStatus; use Aviat\AnimeClient\Hummingbird\Enum\AnimeWatchingStatus;
use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer; use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer;
use Aviat\Ion\Di\ContainerInterface;
/** /**
* Controller for Anime-related pages * Controller for Anime-related pages

View File

@ -16,11 +16,11 @@
namespace Aviat\AnimeClient\Controller; namespace Aviat\AnimeClient\Controller;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\Controller as BaseController; use Aviat\AnimeClient\Controller as BaseController;
use Aviat\AnimeClient\UrlGenerator;
use Aviat\AnimeClient\Model\Anime as AnimeModel; use Aviat\AnimeClient\Model\Anime as AnimeModel;
use Aviat\AnimeClient\Model\AnimeCollection as AnimeCollectionModel; use Aviat\AnimeClient\Model\AnimeCollection as AnimeCollectionModel;
use Aviat\AnimeClient\UrlGenerator;
use Aviat\Ion\Di\ContainerInterface;
/** /**
* Controller for Anime collection pages * Controller for Anime collection pages

View File

@ -16,12 +16,12 @@
namespace Aviat\AnimeClient\Controller; namespace Aviat\AnimeClient\Controller;
use Aviat\Ion\Json;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\Controller; use Aviat\AnimeClient\Controller;
use Aviat\AnimeClient\Model\Manga as MangaModel;
use Aviat\AnimeClient\Hummingbird\Enum\MangaReadingStatus; use Aviat\AnimeClient\Hummingbird\Enum\MangaReadingStatus;
use Aviat\AnimeClient\Hummingbird\Transformer\MangaListTransformer; use Aviat\AnimeClient\Hummingbird\Transformer\MangaListTransformer;
use Aviat\AnimeClient\Model\Manga as MangaModel;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\Ion\Json;
/** /**
* Controller for manga list * Controller for manga list

View File

@ -16,7 +16,10 @@
namespace Aviat\AnimeClient; namespace Aviat\AnimeClient;
use Aviat\Ion\{ArrayWrapper, StringWrapper}; use Aviat\Ion\
{
ArrayWrapper, StringWrapper
};
use Aviat\Ion\Di\ContainerInterface; use Aviat\Ion\Di\ContainerInterface;
/** /**

View File

@ -16,14 +16,13 @@
namespace Aviat\AnimeClient\Model; namespace Aviat\AnimeClient\Model;
use Aviat\AnimeClient\AnimeClient;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\Ion\Model;
use GuzzleHttp\Client; use GuzzleHttp\Client;
use GuzzleHttp\Cookie\CookieJar; use GuzzleHttp\Cookie\CookieJar;
use Psr\Http\Message\ResponseInterface; use Psr\Http\Message\ResponseInterface;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\Ion\Model;
use Aviat\AnimeClient\AnimeClient;
/** /**
* Base model for api interaction * Base model for api interaction
* *

View File

@ -16,9 +16,9 @@
namespace Aviat\AnimeClient\Model; namespace Aviat\AnimeClient\Model;
use Aviat\Ion\Json;
use Aviat\AnimeClient\Hummingbird\Enum\AnimeWatchingStatus; use Aviat\AnimeClient\Hummingbird\Enum\AnimeWatchingStatus;
use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer; use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer;
use Aviat\Ion\Json;
/** /**
* Model for handling requests dealing with the anime list * Model for handling requests dealing with the anime list

View File

@ -16,8 +16,8 @@
namespace Aviat\AnimeClient\Model; namespace Aviat\AnimeClient\Model;
use Aviat\Ion\Json;
use Aviat\Ion\Di\ContainerInterface; use Aviat\Ion\Di\ContainerInterface;
use Aviat\Ion\Json;
/** /**
* Model for getting anime collection data * Model for getting anime collection data

View File

@ -16,8 +16,8 @@
namespace Aviat\AnimeClient\Model; namespace Aviat\AnimeClient\Model;
use Aviat\AnimeClient\Hummingbird\Transformer;
use Aviat\AnimeClient\Hummingbird\Enum\MangaReadingStatus; use Aviat\AnimeClient\Hummingbird\Enum\MangaReadingStatus;
use Aviat\AnimeClient\Hummingbird\Transformer;
use Aviat\Ion\Json; use Aviat\Ion\Json;
use GuzzleHttp\Cookie\SetCookie; use GuzzleHttp\Cookie\SetCookie;
use RuntimeException; use RuntimeException;

View File

@ -1,7 +1,5 @@
<?php <?php
use Aviat\AnimeClient\AnimeClient;
class AnimeClientTest extends AnimeClient_TestCase { class AnimeClientTest extends AnimeClient_TestCase {

View File

@ -1,15 +1,14 @@
<?php <?php
use Aura\Web\WebFactory; use Aura\Web\WebFactory;
use Aviat\AnimeClient\AnimeClient;
use Aviat\Ion\Json;
use GuzzleHttp\Client; use GuzzleHttp\Client;
use GuzzleHttp\Handler\MockHandler; use GuzzleHttp\Handler\MockHandler;
use GuzzleHttp\HandlerStack; use GuzzleHttp\HandlerStack;
use GuzzleHttp\Psr7\Response; use GuzzleHttp\Psr7\Response;
use Zend\Diactoros\ServerRequestFactory;
use Zend\Diactoros\Response as HttpResponse; use Zend\Diactoros\Response as HttpResponse;
use Zend\Diactoros\ServerRequestFactory;
use Aviat\Ion\Json;
use Aviat\AnimeClient\AnimeClient;
define('ROOT_DIR', __DIR__ . '/../'); define('ROOT_DIR', __DIR__ . '/../');
define('TEST_DATA_DIR', __DIR__ . '/test_data'); define('TEST_DATA_DIR', __DIR__ . '/test_data');

View File

@ -1,13 +1,12 @@
<?php <?php
use Aura\Session\SessionFactory; use Aura\Session\SessionFactory;
use Aviat\AnimeClient\Auth\HummingbirdAuth;
use Aviat\Ion\Friend;
use GuzzleHttp\Client; use GuzzleHttp\Client;
use GuzzleHttp\Handler\MockHandler; use GuzzleHttp\Handler\MockHandler;
use GuzzleHttp\HandlerStack; use GuzzleHttp\HandlerStack;
use GuzzleHttp\Psr7\Response; use GuzzleHttp\Psr7\Response;
use Aviat\Ion\Friend;
use Aviat\AnimeClient\Auth\HummingbirdAuth;
class HummingbirdAuthTest extends AnimeClient_TestCase { class HummingbirdAuthTest extends AnimeClient_TestCase {
static $session; static $session;

View File

@ -1,8 +1,8 @@
<?php <?php
use ConsoleKit\Console;
use Aviat\Ion\Friend;
use Aviat\AnimeClient\Command\BaseCommand; use Aviat\AnimeClient\Command\BaseCommand;
use Aviat\Ion\Friend;
use ConsoleKit\Console;
class BaseCommandTest extends AnimeClient_TestCase { class BaseCommandTest extends AnimeClient_TestCase {
public function setUp() public function setUp()

View File

@ -1,10 +1,10 @@
<?php <?php
use \Aviat\AnimeClient\Controller; use Aura\Router\RouterFactory;
use Aura\Web\WebFactory;
use Aviat\AnimeClient\Controller;
use Aviat\AnimeClient\Controller\Anime as AnimeController; use Aviat\AnimeClient\Controller\Anime as AnimeController;
use Aviat\AnimeClient\Controller\Manga as MangaController;
use Aviat\AnimeClient\Controller\Collection as CollectionController; use Aviat\AnimeClient\Controller\Collection as CollectionController;
use \Aura\Web\WebFactory; use Aviat\AnimeClient\Controller\Manga as MangaController;
use \Aura\Router\RouterFactory;
class ControllerTest extends AnimeClient_TestCase { class ControllerTest extends AnimeClient_TestCase {

View File

@ -1,15 +1,10 @@
<?php <?php
use Aura\Router\RouterContainer;
use Monolog\Logger;
use Monolog\Handler\TestHandler;
use Zend\Diactoros\ServerRequestFactory;
use Zend\Diactoros\Response;
use Aviat\Ion\Config;
use Aviat\Ion\Di\Container;
use Aviat\AnimeClient\Dispatcher; use Aviat\AnimeClient\Dispatcher;
use Aviat\AnimeClient\UrlGenerator; use Aviat\AnimeClient\UrlGenerator;
use Aviat\Ion\Config;
use Monolog\Handler\TestHandler;
use Monolog\Logger;
class DispatcherTest extends AnimeClient_TestCase { class DispatcherTest extends AnimeClient_TestCase {

View File

@ -1,7 +1,6 @@
<?php <?php
use Aviat\Ion\Friend;
use Aviat\AnimeClient\MenuGenerator; use Aviat\AnimeClient\MenuGenerator;
use Aviat\Ion\Friend;
class MenuGeneratorTest extends AnimeClient_TestCase { class MenuGeneratorTest extends AnimeClient_TestCase {

View File

@ -1,10 +1,9 @@
<?php <?php
use Aviat\AnimeClient\Model\AnimeCollection as AnimeCollectionModel;
use Aviat\Ion\Config; use Aviat\Ion\Config;
use Aviat\Ion\Friend; use Aviat\Ion\Friend;
use Aviat\AnimeClient\Model\AnimeCollection as AnimeCollectionModel;
class AnimeCollectionModelTest extends AnimeClient_TestCase { class AnimeCollectionModelTest extends AnimeClient_TestCase {
public function setUp() public function setUp()

View File

@ -1,7 +1,5 @@
<?php <?php
use Aviat\Ion\Friend; use Aviat\Ion\Friend;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\Model\Anime as AnimeModel;
class AnimeModelTest extends AnimeClient_TestCase { class AnimeModelTest extends AnimeClient_TestCase {

View File

@ -1,14 +1,11 @@
<?php <?php
use Aviat\AnimeClient\Container;
use GuzzleHttp\Client; use GuzzleHttp\Client;
use GuzzleHttp\Handler\MockHandler; use GuzzleHttp\Handler\MockHandler;
use GuzzleHttp\HandlerStack; use GuzzleHttp\HandlerStack;
use GuzzleHttp\Psr7\Response; use GuzzleHttp\Psr7\Response;
use Aviat\Ion\Di\ContainerInterface;
use Aviat\AnimeClient\Container;
use Aviat\AnimeClient\Model\API as BaseApiModel;
class BaseApiModelTest extends AnimeClient_TestCase { class BaseApiModelTest extends AnimeClient_TestCase {
public function setUp() public function setUp()

View File

@ -1,8 +1,8 @@
<?php <?php
use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer;
use Aviat\Ion\Friend; use Aviat\Ion\Friend;
use Aviat\Ion\Json; use Aviat\Ion\Json;
use Aviat\AnimeClient\Hummingbird\Transformer\AnimeListTransformer;
class AnimeListTransformerTest extends AnimeClient_TestCase { class AnimeListTransformerTest extends AnimeClient_TestCase {

View File

@ -1,7 +1,7 @@
<?php <?php
use Aviat\Ion\Json;
use Aviat\AnimeClient\Hummingbird\Transformer\MangaListTransformer; use Aviat\AnimeClient\Hummingbird\Transformer\MangaListTransformer;
use Aviat\Ion\Json;
class MangaListTransformerTest extends AnimeClient_TestCase { class MangaListTransformerTest extends AnimeClient_TestCase {

View File

@ -1,7 +1,7 @@
<?php <?php
use Aviat\Ion\Json;
use Aviat\AnimeClient\Hummingbird\Transformer\MangaListsZipper; use Aviat\AnimeClient\Hummingbird\Transformer\MangaListsZipper;
use Aviat\Ion\Json;
class MangaListsZipperTest extends AnimeClient_TestCase { class MangaListsZipperTest extends AnimeClient_TestCase {

View File

@ -1,7 +1,7 @@
<?php <?php
use Aviat\Ion\Config;
use Aviat\AnimeClient\UrlGenerator; use Aviat\AnimeClient\UrlGenerator;
use Aviat\Ion\Config;
class UrlGeneratorTest extends AnimeClient_TestCase { class UrlGeneratorTest extends AnimeClient_TestCase {

View File

@ -3,6 +3,9 @@
* All the mock classes that extend the classes they are used to test * All the mock classes that extend the classes they are used to test
*/ */
use Aviat\AnimeClient\Model\Anime as AnimeModel;
use Aviat\AnimeClient\Model\API as BaseApiModel;
use Aviat\AnimeClient\Model\Manga as MangaModel;
use Aviat\Ion\Enum; use Aviat\Ion\Enum;
use Aviat\Ion\Friend; use Aviat\Ion\Friend;
use Aviat\Ion\Json; use Aviat\Ion\Json;
@ -12,10 +15,6 @@ use Aviat\Ion\View\HtmlView;
use Aviat\Ion\View\HttpView; use Aviat\Ion\View\HttpView;
use Aviat\Ion\View\JsonView; use Aviat\Ion\View\JsonView;
use Aviat\AnimeClient\Model\Anime as AnimeModel;
use Aviat\AnimeClient\Model\Manga as MangaModel;
use Aviat\AnimeClient\Model\API as BaseApiModel;
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// Mock the default error handler // Mock the default error handler