Completed
Pull Request — master (#19)
by
unknown
01:09
created

TaggableStub   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Dependencies 1

Importance

Changes 0
Metric Value
wmc 4
cbo 1
dl 0
loc 20
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A addTag() 0 3 1
A getTagNames() 0 4 1
A getTags() 0 4 1
A removeTag() 0 3 1
1
<?php
2
3
namespace Beelab\TagBundle\Test;
4
5
use Beelab\TagBundle\Tag\TaggableInterface;
6
use Beelab\TagBundle\Tag\TagInterface;
7
8
/**
9
 * A stub of a Taggable class.
10
 */
11
class TaggableStub implements TaggableInterface
12
{
13
    public function addTag(TagInterface $tag): void
14
    {
15
    }
16
17
    public function getTagNames(): array
18
    {
19
        return ['foo', 'bar'];
20
    }
21
22
    public function getTags(): iterable
23
    {
24
        return [new TagStub()];
25
    }
26
27
    public function removeTag(TagInterface $tag): void
28
    {
29
    }
30
}
31