Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
CRAP
100.00% covered (success)
100.00%
1 / 1
UuidV3
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
1 / 1
 createRandom
100.00% covered (success)
100.00%
4 / 4
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2namespace Apie\Core\Identifiers;
3
4use Apie\Core\Attributes\FakeMethod;
5use Faker\Generator;
6use Ramsey\Uuid\Uuid as RamseyUuid;
7
8#[FakeMethod("createRandom")]
9class UuidV3 extends Uuid
10{
11    public static function createRandom(Generator $generator): self
12    {
13        return static::fromNative(RamseyUuid::uuid3(
14            RamseyUuid::NAMESPACE_URL,
15            $generator->url()
16        )->toString());
17    }
18}