Completed
Push — master ( 81acf3...241a18 )
by
unknown
60:32 queued 45:22
created

InMemoryVariationHandler   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A getVariation() 0 10 1
1
<?php
2
3
/**
4
 * @copyright Copyright (C) eZ Systems AS. All rights reserved.
5
 * @license For full copyright and license information view LICENSE file distributed with this source code.
6
 */
7
declare(strict_types=1);
8
9
namespace eZ\Publish\SPI\Tests\Variation;
10
11
use eZ\Publish\API\Repository\Values\Content\Field;
12
use eZ\Publish\API\Repository\Values\Content\VersionInfo;
13
use eZ\Publish\SPI\Variation\Values\Variation;
14
use eZ\Publish\SPI\Variation\VariationHandler;
15
16
class InMemoryVariationHandler implements VariationHandler
17
{
18
    public function getVariation(
19
        Field $field,
20
        VersionInfo $versionInfo,
21
        $variationName,
22
        array $parameters = []
23
    ) {
24
        return new Variation([
25
            'uri' => $field->value . '-in-memory-test',
26
        ]);
27
    }
28
}
29