Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,7 @@
</file>
<file src="tests/Unit/Schema/DoctrineSchemaSubscriberTest.php">
<DeprecatedClass>
<code><![CDATA[DoctrineSchemaSubscriber::class]]></code>
<code><![CDATA[new DoctrineSchemaSubscriber($schemaConfigurator->reveal())]]></code>
<code><![CDATA[new DoctrineSchemaSubscriber($schemaConfigurator->reveal())]]></code>
</DeprecatedClass>
Expand Down Expand Up @@ -512,10 +513,16 @@
</file>
<file src="tests/Unit/Subscription/Subscriber/ArgumentResolver/AggregateIdArgumentResolverTest.php">
<DeprecatedClass>
<code><![CDATA[AggregateIdArgumentResolver::class]]></code>
<code><![CDATA[new AggregateIdArgumentResolver()]]></code>
<code><![CDATA[new AggregateIdArgumentResolver()]]></code>
</DeprecatedClass>
</file>
<file src="tests/Unit/Subscription/Subscriber/ArgumentResolver/LookupResolverTest.php">
<DeprecatedClass>
<code><![CDATA[AggregateIdArgumentResolver::class]]></code>
</DeprecatedClass>
</file>
<file src="tests/Unit/Subscription/Subscriber/MetadataSubscriberAccessorRepositoryTest.php">
<DeprecatedClass>
<code><![CDATA[new ArgumentResolver\AggregateIdArgumentResolver()]]></code>
Expand Down
3 changes: 2 additions & 1 deletion tests/Integration/BankAccountSplitStream/IntegrationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@
use Patchlevel\EventSourcing\Tests\Integration\BankAccountSplitStream\Events\BankAccountCreated;
use Patchlevel\EventSourcing\Tests\Integration\BankAccountSplitStream\Events\MonthPassed;
use Patchlevel\EventSourcing\Tests\Integration\BankAccountSplitStream\Projection\BankAccountProjector;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;

use function count;
use function iterator_to_array;

/** @coversNothing */
#[CoversNothing]
final class IntegrationTest extends TestCase
{
private Connection $connection;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,11 @@
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\MessageDecorator\FooMessageDecorator;
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\Processor\SendEmailProcessor;
use Patchlevel\EventSourcing\Tests\Integration\BasicImplementation\Projection\ProfileProjector;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;
use Psr\Clock\ClockInterface;

/** @coversNothing */
#[CoversNothing]
final class BasicIntegrationTest extends TestCase
{
private Connection $connection;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@
use Patchlevel\EventSourcing\Subscription\Subscriber\MetadataSubscriberAccessorRepository;
use Patchlevel\EventSourcing\Tests\DbalManager;
use Patchlevel\EventSourcing\Tests\Integration\ChildAggregate\Projection\ProfileProjector;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;

/** @coversNothing */
#[CoversNothing]
final class ChildAggregateIntegrationTest extends TestCase
{
private Connection $connection;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@
use Patchlevel\EventSourcing\Subscription\Subscriber\MetadataSubscriberAccessorRepository;
use Patchlevel\EventSourcing\Tests\DbalManager;
use Patchlevel\EventSourcing\Tests\Integration\MicroAggregate\Projection\ProfileProjector;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;

/** @coversNothing */
#[CoversNothing]
final class MicroAggregateIntegrationTest extends TestCase
{
private Connection $connection;
Expand Down
3 changes: 2 additions & 1 deletion tests/Integration/PersonalData/PersonalDataTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
use Patchlevel\EventSourcing\Tests\DbalManager;
use Patchlevel\EventSourcing\Tests\Integration\PersonalData\Processor\DeletePersonalDataProcessor;
use Patchlevel\Hydrator\Cryptography\PersonalDataPayloadCryptographer;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;

/** @coversNothing */
#[CoversNothing]
final class PersonalDataTest extends TestCase
{
private Connection $connection;
Expand Down
3 changes: 2 additions & 1 deletion tests/Integration/Store/DoctrineDbalStoreTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@
use Patchlevel\EventSourcing\Store\UniqueConstraintViolation;
use Patchlevel\EventSourcing\Tests\DbalManager;
use Patchlevel\EventSourcing\Tests\Integration\Store\Events\ProfileCreated;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;

use function json_decode;

/** @coversNothing */
#[CoversNothing]
final class DoctrineDbalStoreTest extends TestCase
{
private Connection $connection;
Expand Down
3 changes: 2 additions & 1 deletion tests/Integration/Store/StreamDoctrineDbalStoreTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,15 @@
use Patchlevel\EventSourcing\Tests\DbalManager;
use Patchlevel\EventSourcing\Tests\Integration\Store\Events\ExternEvent;
use Patchlevel\EventSourcing\Tests\Integration\Store\Events\ProfileCreated;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;
use Psr\Clock\ClockInterface;

use function iterator_to_array;
use function json_decode;
use function sprintf;

/** @coversNothing */
#[CoversNothing]
final class StreamDoctrineDbalStoreTest extends TestCase
{
private Connection $connection;
Expand Down
3 changes: 2 additions & 1 deletion tests/Integration/Subscription/SubscriptionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,15 @@
use Patchlevel\EventSourcing\Tests\Integration\Subscription\Subscriber\ProfileNewProjection;
use Patchlevel\EventSourcing\Tests\Integration\Subscription\Subscriber\ProfileProcessor;
use Patchlevel\EventSourcing\Tests\Integration\Subscription\Subscriber\ProfileProjection;
use PHPUnit\Framework\Attributes\CoversNothing;
use PHPUnit\Framework\TestCase;
use RuntimeException;

use function gc_collect_cycles;
use function iterator_to_array;
use function sprintf;

/** @coversNothing */
#[CoversNothing]
final class SubscriptionTest extends TestCase
{
private Connection $connection;
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/AggregateHeaderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use DateTimeImmutable;
use Patchlevel\EventSourcing\Aggregate\AggregateHeader;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Aggregate\AggregateHeader */
#[CoversClass(AggregateHeader::class)]
final class AggregateHeaderTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/AggregateRootIdNotSupportedTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use Patchlevel\EventSourcing\Aggregate\AggregateRootIdNotSupported;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\Profile;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Aggregate\AggregateRootIdNotSupported */
#[CoversClass(AggregateRootIdNotSupported::class)]
final class AggregateRootIdNotSupportedTest extends TestCase
{
public function testCreate(): void
Expand Down
14 changes: 8 additions & 6 deletions tests/Unit/Aggregate/AggregateRootTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@

namespace Patchlevel\EventSourcing\Tests\Unit\Aggregate;

use Patchlevel\EventSourcing\Aggregate\AggregateRootAttributeBehaviour;
use Patchlevel\EventSourcing\Aggregate\AggregateRootBehaviour;
use Patchlevel\EventSourcing\Aggregate\AggregateRootIdNotSupported;
use Patchlevel\EventSourcing\Aggregate\AggregateRootMetadataAwareBehaviour;
use Patchlevel\EventSourcing\Aggregate\ApplyMethodNotFound;
use Patchlevel\EventSourcing\Aggregate\BasicAggregateRoot;
use Patchlevel\EventSourcing\Aggregate\MetadataNotPossible;
Expand All @@ -25,15 +28,14 @@
use Patchlevel\EventSourcing\Tests\Unit\Fixture\ProfileInvalid;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\ProfileWithBrokenId;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\ProfileWithSuppressAll;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\RunInSeparateProcess;
use PHPUnit\Framework\TestCase;

/**
* @covers \Patchlevel\EventSourcing\Aggregate\BasicAggregateRoot
* @covers \Patchlevel\EventSourcing\Aggregate\AggregateRootBehaviour
* @covers \Patchlevel\EventSourcing\Aggregate\AggregateRootAttributeBehaviour
* @covers \Patchlevel\EventSourcing\Aggregate\AggregateRootMetadataAwareBehaviour
*/
#[CoversClass(BasicAggregateRoot::class)]
#[CoversClass(AggregateRootBehaviour::class)]
#[CoversClass(AggregateRootAttributeBehaviour::class)]
#[CoversClass(AggregateRootMetadataAwareBehaviour::class)]
final class AggregateRootTest extends TestCase
{
public function testApplyMethod(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/ApplyMethodNotFoundTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
use Patchlevel\EventSourcing\Aggregate\ApplyMethodNotFound;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\Profile;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\ProfileCreated;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Aggregate\ApplyMethodNotFound */
#[CoversClass(ApplyMethodNotFound::class)]
final class ApplyMethodNotFoundTest extends TestCase
{
public function testCreate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/CustomIdTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Aggregate;

use Patchlevel\EventSourcing\Aggregate\CustomId;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Aggregate\CustomId */
#[CoversClass(CustomId::class)]
final class CustomIdTest extends TestCase
{
public function testFromString(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/MetadataNotPossibleTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Aggregate;

use Patchlevel\EventSourcing\Aggregate\MetadataNotPossible;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Aggregate\MetadataNotPossible */
#[CoversClass(MetadataNotPossible::class)]
final class MetadataNotPossibleTest extends TestCase
{
public function testCreate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Aggregate/UuidTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,13 @@

use DateTimeInterface;
use Patchlevel\EventSourcing\Aggregate\Uuid;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;
use Ramsey\Uuid\Uuid as RamseyUuid;
use Ramsey\Uuid\UuidFactory;
use Ramsey\Uuid\UuidInterface;

/** @covers \Patchlevel\EventSourcing\Aggregate\Uuid */
#[CoversClass(Uuid::class)]
final class UuidTest extends TestCase
{
public function testFromString(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/AggregateTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Aggregate;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Aggregate */
#[CoversClass(Aggregate::class)]
final class AggregateTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/ApplyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use Patchlevel\EventSourcing\Attribute\Apply;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\Profile;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Apply */
#[CoversClass(Apply::class)]
final class ApplyTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/EventTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Event;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Event */
#[CoversClass(Event::class)]
final class EventTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/HeaderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Header;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Header */
#[CoversClass(Header::class)]
final class HeaderTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/IdTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Id;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DoesNotPerformAssertions;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Id */
#[CoversClass(Id::class)]
final class IdTest extends TestCase
{
#[DoesNotPerformAssertions]
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SetupTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Setup;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DoesNotPerformAssertions;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Setup */
#[CoversClass(Setup::class)]
final class SetupTest extends TestCase
{
#[DoesNotPerformAssertions]
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SnapshotTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Snapshot;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Snapshot */
#[CoversClass(Snapshot::class)]
final class SnapshotTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SplitStreamTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\SplitStream;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DoesNotPerformAssertions;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\SplitStream */
#[CoversClass(SplitStream::class)]
final class SplitStreamTest extends TestCase
{
#[DoesNotPerformAssertions]
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SubscribeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use Patchlevel\EventSourcing\Attribute\Subscribe;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\Profile;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Subscribe */
#[CoversClass(Subscribe::class)]
final class SubscribeTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SubscriberTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use Patchlevel\EventSourcing\Attribute\Subscriber;
use Patchlevel\EventSourcing\Subscription\RunMode;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Subscriber */
#[CoversClass(Subscriber::class)]
final class SubscriberTest extends TestCase
{
public function testInstantiate(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/SuppressMissingApplyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@

use Patchlevel\EventSourcing\Attribute\SuppressMissingApply;
use Patchlevel\EventSourcing\Tests\Unit\Fixture\ProfileCreated;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\SuppressMissingApply */
#[CoversClass(SuppressMissingApply::class)]
final class SuppressMissingApplyTest extends TestCase
{
public function testSuppressEvents(): void
Expand Down
3 changes: 2 additions & 1 deletion tests/Unit/Attribute/TeardownTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@
namespace Patchlevel\EventSourcing\Tests\Unit\Attribute;

use Patchlevel\EventSourcing\Attribute\Teardown;
use PHPUnit\Framework\Attributes\CoversClass;
use PHPUnit\Framework\Attributes\DoesNotPerformAssertions;
use PHPUnit\Framework\TestCase;

/** @covers \Patchlevel\EventSourcing\Attribute\Teardown */
#[CoversClass(Teardown::class)]
final class TeardownTest extends TestCase
{
#[DoesNotPerformAssertions]
Expand Down
Loading
Loading