Skip to content

Commit

Permalink
Add missing token for "codecov/codecov-action" at "upload_coverage" C…
Browse files Browse the repository at this point in the history
…I job
  • Loading branch information
phansys committed Oct 8, 2024
1 parent eabb450 commit c5798aa
Show file tree
Hide file tree
Showing 118 changed files with 878 additions and 1,286 deletions.
6 changes: 2 additions & 4 deletions tests/Gedmo/Blameable/BlameableDocumentTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ final class BlameableDocumentTest extends BaseTestCaseMongoODM
{
private const TEST_USERNAME = 'testuser';

private const ARTICLE = Article::class;

protected function setUp(): void
{
parent::setUp();
Expand All @@ -50,7 +48,7 @@ protected function setUp(): void

public function testBlameable(): void
{
$repo = $this->dm->getRepository(self::ARTICLE);
$repo = $this->dm->getRepository(Article::class);
$article = $repo->findOneBy(['title' => 'Blameable Article']);

static::assertSame(self::TEST_USERNAME, $article->getCreated());
Expand Down Expand Up @@ -81,7 +79,7 @@ public function testForcedValues(): void
$this->dm->persist($sport);
$this->dm->flush();

$repo = $this->dm->getRepository(self::ARTICLE);
$repo = $this->dm->getRepository(Article::class);
$sport = $repo->findOneBy(['title' => 'sport forced']);
static::assertSame(self::TEST_USERNAME, $sport->getCreated());
static::assertSame(self::TEST_USERNAME, $sport->getUpdated());
Expand Down
18 changes: 7 additions & 11 deletions tests/Gedmo/Blameable/BlameableTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@
*/
final class BlameableTest extends BaseTestCaseORM
{
private const ARTICLE = Article::class;
private const COMMENT = Comment::class;
private const TYPE = Type::class;

protected function setUp(): void
{
parent::setUp();
Expand Down Expand Up @@ -62,12 +58,12 @@ public function testBlameable(): void
$this->em->flush();
$this->em->clear();

$sport = $this->em->getRepository(self::ARTICLE)->findOneBy(['title' => 'Sport']);
$sport = $this->em->getRepository(Article::class)->findOneBy(['title' => 'Sport']);
static::assertSame('testuser', $sport->getCreated());
static::assertSame('testuser', $sport->getUpdated());
static::assertNull($sport->getPublished());

$sportComment = $this->em->getRepository(self::COMMENT)->findOneBy(['message' => 'hello']);
$sportComment = $this->em->getRepository(Comment::class)->findOneBy(['message' => 'hello']);
static::assertSame('testuser', $sportComment->getModified());
static::assertNull($sportComment->getClosed());

Expand All @@ -83,7 +79,7 @@ public function testBlameable(): void
$this->em->flush();
$this->em->clear();

$sportComment = $this->em->getRepository(self::COMMENT)->findOneBy(['message' => 'hello']);
$sportComment = $this->em->getRepository(Comment::class)->findOneBy(['message' => 'hello']);
static::assertSame('testuser', $sportComment->getClosed());

static::assertSame('testuser', $sport->getPublished());
Expand All @@ -100,7 +96,7 @@ public function testForcedValues(): void
$this->em->flush();
$this->em->clear();

$repo = $this->em->getRepository(self::ARTICLE);
$repo = $this->em->getRepository(Article::class);
$sport = $repo->findOneBy(['title' => 'sport forced']);
static::assertSame('myuser', $sport->getCreated());
static::assertSame('myuser', $sport->getUpdated());
Expand All @@ -122,9 +118,9 @@ public function testForcedValues(): void
protected function getUsedEntityFixtures(): array
{
return [
self::ARTICLE,
self::COMMENT,
self::TYPE,
Article::class,
Comment::class,
Type::class,
];
}
}
6 changes: 2 additions & 4 deletions tests/Gedmo/Blameable/BlameableUuidTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@

final class BlameableUuidTest extends BaseTestCaseORM
{
private const COMPANY = Company::class;

private UuidV6 $uuid;

protected function setUp(): void
Expand Down Expand Up @@ -54,7 +52,7 @@ public function testBlameableUuid(): void
/**
* @var Company $foundCompany
*/
$foundCompany = $this->em->getRepository(self::COMPANY)->findOneBy(['name' => 'ACME']);
$foundCompany = $this->em->getRepository(Company::class)->findOneBy(['name' => 'ACME']);
$created = $foundCompany->getCreated();
$createdUuid = $created instanceof Uuid ? $created->toRfc4122() : null;

Expand All @@ -64,7 +62,7 @@ public function testBlameableUuid(): void
protected function getUsedEntityFixtures(): array
{
return [
self::COMPANY,
Company::class,
];
}
}
8 changes: 3 additions & 5 deletions tests/Gedmo/Blameable/ChangeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
*/
final class ChangeTest extends BaseTestCaseORM
{
private const FIXTURE = TitledArticle::class;

private BlameableListener $listener;

protected function setUp(): void
Expand All @@ -49,7 +47,7 @@ public function testChange(): void
$this->em->flush();
$this->em->clear();

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'Test']);
$test = $this->em->getRepository(TitledArticle::class)->findOneBy(['title' => 'Test']);
$test->setTitle('New Title');
$this->em->persist($test);
$this->em->flush();
Expand All @@ -59,7 +57,7 @@ public function testChange(): void

$this->listener->setUserValue('otheruser');

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'New Title']);
$test = $this->em->getRepository(TitledArticle::class)->findOneBy(['title' => 'New Title']);
$test->setText('New Text');
$this->em->persist($test);
$this->em->flush();
Expand All @@ -71,7 +69,7 @@ public function testChange(): void
protected function getUsedEntityFixtures(): array
{
return [
self::FIXTURE,
TitledArticle::class,
];
}
}
6 changes: 2 additions & 4 deletions tests/Gedmo/Blameable/NoInterfaceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
*/
final class NoInterfaceTest extends BaseTestCaseORM
{
private const FIXTURE = WithoutInterface::class;

protected function setUp(): void
{
parent::setUp();
Expand All @@ -46,15 +44,15 @@ public function testBlameableNoInterface(): void
$this->em->flush();
$this->em->clear();

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'Test']);
$test = $this->em->getRepository(WithoutInterface::class)->findOneBy(['title' => 'Test']);
static::assertSame('testuser', $test->getCreated());
static::assertSame('testuser', $test->getUpdated());
}

protected function getUsedEntityFixtures(): array
{
return [
self::FIXTURE,
WithoutInterface::class,
];
}
}
4 changes: 1 addition & 3 deletions tests/Gedmo/Blameable/NoUserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
*/
final class NoUserTest extends BaseTestCaseMongoODM
{
private const ARTICLE = Article::class;

protected function setUp(): void
{
parent::setUp();
Expand All @@ -47,7 +45,7 @@ public function testWhenNoUserIsAvailable(): void
$this->dm->flush();
$this->dm->clear();

$repo = $this->dm->getRepository(self::ARTICLE);
$repo = $this->dm->getRepository(Article::class);
$sport = $repo->findOneBy(['title' => 'sport no user']);
static::assertEmpty($sport->getCreated());
static::assertEmpty($sport->getUpdated());
Expand Down
9 changes: 3 additions & 6 deletions tests/Gedmo/Blameable/ProtectedPropertySupperclassTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@
*/
final class ProtectedPropertySupperclassTest extends BaseTestCaseORM
{
private const SUPERCLASS = SupperClassExtension::class;
private const TRANSLATION = Translation::class;

protected function setUp(): void
{
parent::setUp();
Expand All @@ -53,7 +50,7 @@ public function testProtectedProperty(): void
$this->em->flush();
$this->em->clear();

$repo = $this->em->getRepository(self::TRANSLATION);
$repo = $this->em->getRepository(Translation::class);
$translations = $repo->findTranslations($test);
static::assertCount(0, $translations);

Expand All @@ -63,8 +60,8 @@ public function testProtectedProperty(): void
protected function getUsedEntityFixtures(): array
{
return [
self::TRANSLATION,
self::SUPERCLASS,
Translation::class,
SupperClassExtension::class,
];
}
}
8 changes: 3 additions & 5 deletions tests/Gedmo/Blameable/TraitUsageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
*/
final class TraitUsageTest extends BaseTestCaseORM
{
private const TARGET = UsingTrait::class;

protected function setUp(): void
{
parent::setUp();
Expand Down Expand Up @@ -52,14 +50,14 @@ public function testShouldTimestampUsingTrait(): void
public function testTraitMethodthShouldReturnObject(): void
{
$sport = new UsingTrait();
static::assertInstanceOf(self::TARGET, $sport->setCreatedBy('myuser'));
static::assertInstanceOf(self::TARGET, $sport->setUpdatedBy('myuser'));
static::assertInstanceOf(UsingTrait::class, $sport->setCreatedBy('myuser'));
static::assertInstanceOf(UsingTrait::class, $sport->setUpdatedBy('myuser'));
}

protected function getUsedEntityFixtures(): array
{
return [
self::TARGET,
UsingTrait::class,
];
}
}
7 changes: 3 additions & 4 deletions tests/Gedmo/IpTraceable/ChangeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
final class ChangeTest extends BaseTestCaseORM
{
private const TEST_IP = '34.234.1.10';
private const FIXTURE = TitledArticle::class;

/**
* @var IpTraceableListener
Expand Down Expand Up @@ -54,7 +53,7 @@ public function testChange(): void
$this->em->flush();
$this->em->clear();

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'Test']);
$test = $this->em->getRepository(TitledArticle::class)->findOneBy(['title' => 'Test']);
$test->setTitle('New Title');
$this->em->persist($test);
$this->em->flush();
Expand All @@ -64,7 +63,7 @@ public function testChange(): void

$this->listener->setIpValue('127.0.0.1');

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'New Title']);
$test = $this->em->getRepository(TitledArticle::class)->findOneBy(['title' => 'New Title']);
$test->setText('New Text');
$this->em->persist($test);
$this->em->flush();
Expand All @@ -76,7 +75,7 @@ public function testChange(): void
protected function getUsedEntityFixtures(): array
{
return [
self::FIXTURE,
TitledArticle::class,
];
}
}
6 changes: 2 additions & 4 deletions tests/Gedmo/IpTraceable/IpTraceableDocumentTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ final class IpTraceableDocumentTest extends BaseTestCaseMongoODM
{
private const TEST_IP = '34.234.1.10';

private const ARTICLE = Article::class;

protected function setUp(): void
{
parent::setUp();
Expand All @@ -44,7 +42,7 @@ protected function setUp(): void

public function testIpTraceable(): void
{
$repo = $this->dm->getRepository(self::ARTICLE);
$repo = $this->dm->getRepository(Article::class);
$article = $repo->findOneBy(['title' => 'IpTraceable Article']);

static::assertSame(self::TEST_IP, $article->getCreated());
Expand Down Expand Up @@ -77,7 +75,7 @@ public function testForcedValues(): void
$this->dm->flush();
$this->dm->clear();

$repo = $this->dm->getRepository(self::ARTICLE);
$repo = $this->dm->getRepository(Article::class);
$sport = $repo->findOneBy(['title' => 'sport forced']);
static::assertSame(self::TEST_IP, (string) $sport->getCreated());
static::assertSame(self::TEST_IP, $sport->getUpdated());
Expand Down
18 changes: 7 additions & 11 deletions tests/Gedmo/IpTraceable/IpTraceableTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@ final class IpTraceableTest extends BaseTestCaseORM
{
private const TEST_IP = '34.234.1.10';

private const ARTICLE = Article::class;
private const COMMENT = Comment::class;
private const TYPE = Type::class;

protected function setUp(): void
{
parent::setUp();
Expand Down Expand Up @@ -98,12 +94,12 @@ public function testIpTraceable(): void
$this->em->flush();
$this->em->clear();

$sport = $this->em->getRepository(self::ARTICLE)->findOneBy(['title' => 'Sport']);
$sport = $this->em->getRepository(Article::class)->findOneBy(['title' => 'Sport']);
static::assertSame(self::TEST_IP, $sport->getCreated());
static::assertSame(self::TEST_IP, $sport->getUpdated());
static::assertNull($sport->getPublished());

$sportComment = $this->em->getRepository(self::COMMENT)->findOneBy(['message' => 'hello']);
$sportComment = $this->em->getRepository(Comment::class)->findOneBy(['message' => 'hello']);
static::assertSame(self::TEST_IP, $sportComment->getModified());
static::assertNull($sportComment->getClosed());

Expand All @@ -119,7 +115,7 @@ public function testIpTraceable(): void
$this->em->flush();
$this->em->clear();

$sportComment = $this->em->getRepository(self::COMMENT)->findOneBy(['message' => 'hello']);
$sportComment = $this->em->getRepository(Comment::class)->findOneBy(['message' => 'hello']);
static::assertSame(self::TEST_IP, $sportComment->getClosed());

static::assertSame(self::TEST_IP, $sport->getPublished());
Expand All @@ -136,7 +132,7 @@ public function testForcedValues(): void
$this->em->flush();
$this->em->clear();

$repo = $this->em->getRepository(self::ARTICLE);
$repo = $this->em->getRepository(Article::class);
$sport = $repo->findOneBy(['title' => 'sport forced']);
static::assertSame(self::TEST_IP, $sport->getCreated());
static::assertSame(self::TEST_IP, $sport->getUpdated());
Expand All @@ -158,9 +154,9 @@ public function testForcedValues(): void
protected function getUsedEntityFixtures(): array
{
return [
self::ARTICLE,
self::COMMENT,
self::TYPE,
Article::class,
Comment::class,
Type::class,
];
}
}
5 changes: 2 additions & 3 deletions tests/Gedmo/IpTraceable/NoInterfaceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
final class NoInterfaceTest extends BaseTestCaseORM
{
private const TEST_IP = '34.234.1.10';
private const FIXTURE = WithoutInterface::class;

protected function setUp(): void
{
Expand All @@ -47,15 +46,15 @@ public function testIpTraceableNoInterface(): void
$this->em->flush();
$this->em->clear();

$test = $this->em->getRepository(self::FIXTURE)->findOneBy(['title' => 'Test']);
$test = $this->em->getRepository(WithoutInterface::class)->findOneBy(['title' => 'Test']);
static::assertSame(self::TEST_IP, $test->getCreated());
static::assertSame(self::TEST_IP, $test->getUpdated());
}

protected function getUsedEntityFixtures(): array
{
return [
self::FIXTURE,
WithoutInterface::class,
];
}
}
Loading

0 comments on commit c5798aa

Please sign in to comment.