refactor: reorgeniced Service/ into Provider/ and Renderer/ sub-namespaces #9

Merged
haylan merged 2 commits from refactor/service-namespaces into main 2026-06-03 22:42:43 +00:00
20 changed files with 37 additions and 36 deletions
Showing only changes of commit 2f3268c0b7 - Show all commits
+2 -2
View File
@@ -5,8 +5,8 @@ declare(strict_types=1);
namespace App\Controller;
use App\Service\ContributionAggregator;
use App\Service\ProviderHealthChecker;
use App\Service\SvgRenderer;
use App\Service\Provider\ProviderHealthChecker;
use App\Service\Renderer\SvgRenderer;
use Psr\Log\LoggerInterface;
use Symfony\Component\DependencyInjection\Attribute\Autowire;
use Symfony\Component\HttpFoundation\RedirectResponse;
+1
View File
@@ -4,6 +4,7 @@ declare(strict_types=1);
namespace App\Service;
use App\Service\Provider\ProviderInterface;
use Psr\Log\LoggerInterface;
use Symfony\Component\DependencyInjection\Attribute\AutowireIterator;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
use IDCI\Bundle\GraphQLClientBundle\Client\GraphQLApiClient;
use IDCI\Bundle\GraphQLClientBundle\Client\GraphQLApiClientRegistryInterface;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
use Psr\Log\LoggerInterface;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
use Psr\Log\LoggerInterface;
use Symfony\Contracts\HttpClient\HttpClientInterface;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
use Symfony\Contracts\HttpClient\Exception\HttpExceptionInterface;
use Symfony\Contracts\HttpClient\Exception\TransportExceptionInterface;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
enum ProviderErrorCode: string
{
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
use Symfony\Component\DependencyInjection\Attribute\AutowireIterator;
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
interface ProviderInterface
{
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
final class ProviderStatus
{
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Provider;
enum ProviderStatusType: string
{
@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace App\Service;
namespace App\Service\Renderer;
/**
* Renders a GitHub-style contribution heatmap as an inline SVG.
@@ -5,7 +5,7 @@ declare(strict_types=1);
namespace App\Tests\Unit\Service;
use App\Service\ContributionAggregator;
use App\Service\ProviderInterface;
use App\Service\Provider\ProviderInterface;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,9 +2,9 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\GitHubProvider;
use App\Service\Provider\GitHubProvider;
use IDCI\Bundle\GraphQLClientBundle\Client\GraphQLApiClient;
use IDCI\Bundle\GraphQLClientBundle\Client\GraphQLApiClientRegistryInterface;
use IDCI\Bundle\GraphQLClientBundle\Query\GraphQLQuery;
@@ -2,9 +2,9 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\GitLabProvider;
use App\Service\Provider\GitLabProvider;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,9 +2,9 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\GiteaProvider;
use App\Service\Provider\GiteaProvider;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,12 +2,12 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\ProbeTrait;
use App\Service\ProviderErrorCode;
use App\Service\ProviderInterface;
use App\Service\ProviderStatusType;
use App\Service\Provider\ProbeTrait;
use App\Service\Provider\ProviderErrorCode;
use App\Service\Provider\ProviderInterface;
use App\Service\Provider\ProviderStatusType;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,13 +2,13 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\ProviderErrorCode;
use App\Service\ProviderHealthChecker;
use App\Service\ProviderInterface;
use App\Service\ProviderStatus;
use App\Service\ProviderStatusType;
use App\Service\Provider\ProviderErrorCode;
use App\Service\Provider\ProviderHealthChecker;
use App\Service\Provider\ProviderInterface;
use App\Service\Provider\ProviderStatus;
use App\Service\Provider\ProviderStatusType;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,11 +2,11 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Provider;
use App\Service\ProviderErrorCode;
use App\Service\ProviderStatus;
use App\Service\ProviderStatusType;
use App\Service\Provider\ProviderErrorCode;
use App\Service\Provider\ProviderStatus;
use App\Service\Provider\ProviderStatusType;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;
@@ -2,9 +2,9 @@
declare(strict_types=1);
namespace App\Tests\Unit\Service;
namespace App\Tests\Unit\Service\Renderer;
use App\Service\SvgRenderer;
use App\Service\Renderer\SvgRenderer;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\Attributes\Test;