TestAggregateCreated   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 2
dl 0
loc 16
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A create() 0 7 1
1
<?php declare(strict_types = 1);
2
3
namespace TomCizek\SymfonyProoph\Tests\EventSourcing\FakeImplementations;
4
5
use Prooph\EventSourcing\AggregateChanged;
6
use Prooph\ServiceBus\Async\AsyncMessage;
7
use Ramsey\Uuid\UuidInterface;
8
9
class TestAggregateCreated extends AggregateChanged implements AsyncMessage
10
{
11
	private const TEST_PAYLOAD_KEY = 'key';
12
	private const TEST_PAYLOAD_VALUE = 'value';
13
	public const TEST_PAYLOAD = [
14
		self::TEST_PAYLOAD_KEY => self::TEST_PAYLOAD_VALUE,
15
	];
16
17
	public static function create(UuidInterface $uuid): AggregateChanged
18
	{
19
		return self::occur(
20
			$uuid->toString(),
21
			self::TEST_PAYLOAD
22
		);
23
	}
24
}
25