Skip to content

Commit

Permalink
Fix CGL
Browse files Browse the repository at this point in the history
  • Loading branch information
d-s-codappix committed Jan 15, 2025
1 parent 6bced3c commit a40cc0e
Show file tree
Hide file tree
Showing 7 changed files with 70 additions and 70 deletions.
34 changes: 17 additions & 17 deletions Tests/Unit/Domain/Model/Dto/DateDemandFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class DateDemandFactoryTest extends TestCase
#[Test]
public function canBeCreated(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -52,7 +52,7 @@ public function canBeCreated(): void
#[Test]
public function fromSettingsDoesNotThrowUndefinedArrayKeyWarnings(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -69,7 +69,7 @@ public function fromSettingsDoesNotThrowUndefinedArrayKeyWarnings(): void
#[Test]
public function searchWordIsSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -91,7 +91,7 @@ public function searchWordIsSetByRequest(): void
#[Test]
public function synonymsAreSetBySettings(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -130,7 +130,7 @@ public function synonymsAreSetBySettings(): void
#[Test]
public function categoriesAreSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -157,7 +157,7 @@ public function categoriesAreSetByRequest(): void
#[Test]
public function featuresAreSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -184,7 +184,7 @@ public function featuresAreSetByRequest(): void
#[Test]
public function regionIsSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -212,7 +212,7 @@ public function regionIsSetByRequest(): void
#[Test]
public function regionsAreSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -243,7 +243,7 @@ public function regionsAreSetByRequest(): void
#[Test]
public function startIsSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -273,7 +273,7 @@ public function startIsSetByRequest(): void
#[Test]
public function endIsSetByRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -306,7 +306,7 @@ public function returnsEndsOnSameDayIfAnyIsNull(
string $start,
string $end
): void {
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down Expand Up @@ -344,7 +344,7 @@ public static function possibleEndAndStartNullCombinations(): Generator
#[Test]
public function returnsEndsOnSameDayIfBothAreOnSameDay(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -366,7 +366,7 @@ public function returnsEndsOnSameDayIfBothAreOnSameDay(): void
#[Test]
public function returnsEndsOnSameDayIfBothAreOnDifferentDays(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -389,7 +389,7 @@ public function returnsEndsOnSameDayIfBothAreOnDifferentDays(): void
#[Test]
public function returnsHighlightIfSet(mixed $highlight): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -416,7 +416,7 @@ public static function possibleSubmittedHighlights(): Generator
#[Test]
public function returnsNoHighlightIfNotSet(mixed $highlight): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -443,7 +443,7 @@ public static function possibleSubmittedFalsyHighlights(): Generator
#[Test]
public function returnsOrganizersFromSettings(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand All @@ -458,7 +458,7 @@ public function returnsOrganizersFromSettings(): void
#[Test]
public function returnsOrganizersFromRequest(): void
{
$typoScriptService = $this->createStub(TypoScriptService::class);
$typoScriptService = self::createStub(TypoScriptService::class);

$subject = new DateDemandFactory(
$typoScriptService
Expand Down
4 changes: 2 additions & 2 deletions Tests/Unit/Domain/Model/EventTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ public function canBeCreated(): void
#[Test]
public function returnsSortedFeatures(): void
{
$feature1 = $this->createStub(Category::class);
$feature1 = self::createStub(Category::class);
$feature1->method('getSorting')->willReturn(10);
$feature2 = $this->createStub(Category::class);
$feature2 = self::createStub(Category::class);
$feature2->method('getSorting')->willReturn(5);

$storage = new ObjectStorage();
Expand Down
26 changes: 13 additions & 13 deletions Tests/Unit/Domain/Model/ImportTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class ImportTest extends TestCase
#[Test]
public function canBeCreated(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -34,7 +34,7 @@ public function canBeCreated(): void
#[Test]
public function returnsRestExperience(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -52,7 +52,7 @@ public function returnsRestExperience(): void
#[Test]
public function returnsStoragePid(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -70,8 +70,8 @@ public function returnsStoragePid(): void
#[Test]
public function returnsRegion(): void
{
$folder = $this->createStub(Folder::class);
$region = $this->createStub(Region::class);
$folder = self::createStub(Folder::class);
$region = self::createStub(Region::class);

$subject = new Import(
$folder,
Expand All @@ -97,7 +97,7 @@ public function returnsRegion(): void
#[Test]
public function returnsFilesFolder(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -115,7 +115,7 @@ public function returnsFilesFolder(): void
#[Test]
public function returnsCategoriesPid(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -137,8 +137,8 @@ public function returnsCategoriesPid(): void
#[Test]
public function returnsCategoryParent(): void
{
$category = $this->createStub(Category::class);
$folder = $this->createStub(Folder::class);
$category = self::createStub(Category::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -161,7 +161,7 @@ public function returnsCategoryParent(): void
#[Test]
public function returnsFeaturesPid(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -185,8 +185,8 @@ public function returnsFeaturesPid(): void
#[Test]
public function returnsFeaturesParent(): void
{
$feature = $this->createStub(Category::class);
$folder = $this->createStub(Folder::class);
$feature = self::createStub(Category::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand All @@ -211,7 +211,7 @@ public function returnsFeaturesParent(): void
#[Test]
public function returnsSearchQuery(): void
{
$folder = $this->createStub(Folder::class);
$folder = self::createStub(Folder::class);

$subject = new Import(
$folder,
Expand Down
28 changes: 14 additions & 14 deletions Tests/Unit/Events/Controller/DateListVariablesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ public function canBeCreated(): void
$subject = new DateListVariables(
[],
new DateDemand(),
$this->createStub(QueryResult::class),
$this->createStub(PaginationInterface::class)
self::createStub(QueryResult::class),
self::createStub(PaginationInterface::class)
);

self::assertInstanceOf(
Expand All @@ -37,8 +37,8 @@ public function returnsInitialSearch(): void
'executed' => '1',
],
new DateDemand(),
$this->createStub(QueryResult::class),
$this->createStub(PaginationInterface::class)
self::createStub(QueryResult::class),
self::createStub(PaginationInterface::class)
);

self::assertSame(
Expand All @@ -57,8 +57,8 @@ public function returnsInitialDemand(): void
[
],
$demand,
$this->createStub(QueryResult::class),
$this->createStub(PaginationInterface::class)
self::createStub(QueryResult::class),
self::createStub(PaginationInterface::class)
);

self::assertSame(
Expand All @@ -70,13 +70,13 @@ public function returnsInitialDemand(): void
#[Test]
public function returnsInitialDates(): void
{
$dates = $this->createStub(QueryResult::class);
$dates = self::createStub(QueryResult::class);
$subject = new DateListVariables(
[
],
new DateDemand(),
$dates,
$this->createStub(PaginationInterface::class)
self::createStub(PaginationInterface::class)
);

self::assertSame(
Expand All @@ -89,8 +89,8 @@ public function returnsInitialDates(): void
public function returnsInitialVariablesForView(): void
{
$demand = new DateDemand();
$dates = $this->createStub(QueryResult::class);
$pagination = $this->createStub(PaginationInterface::class);
$dates = self::createStub(QueryResult::class);
$pagination = self::createStub(PaginationInterface::class);
$subject = new DateListVariables(
[
'executed' => '1',
Expand All @@ -117,8 +117,8 @@ public function returnsInitialVariablesForView(): void
public function returnsVariablesForViewWithAddedVariables(): void
{
$demand = new DateDemand();
$dates = $this->createStub(QueryResult::class);
$pagination = $this->createStub(PaginationInterface::class);
$dates = self::createStub(QueryResult::class);
$pagination = self::createStub(PaginationInterface::class);
$subject = new DateListVariables(
[
'executed' => '1',
Expand Down Expand Up @@ -150,8 +150,8 @@ public function returnsVariablesForViewWithAddedVariables(): void
public function returnsVariablesForViewWithOverwrittenVariables(): void
{
$demand = new DateDemand();
$dates = $this->createStub(QueryResult::class);
$pagination = $this->createStub(PaginationInterface::class);
$dates = self::createStub(QueryResult::class);
$pagination = self::createStub(PaginationInterface::class);
$subject = new DateListVariables(
[
'executed' => '1',
Expand Down
Loading

0 comments on commit a40cc0e

Please sign in to comment.