Completed
Push — master ( fef923...c0df34 )
by Rafael
03:03
created

LevenshteinMatcherTest   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
c 1
b 0
f 0
lcom 0
cbo 2
dl 0
loc 35
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A buildMatcher() 0 4 1
A getEquals() 0 9 1
A getNotEquals() 0 7 1
1
<?php
2
3
/**
4
 * LICENSE: This file is subject to the terms and conditions defined in
5
 * file 'LICENSE', which is part of this source code package.
6
 *
7
 * @copyright 2016 Copyright(c) - All rights reserved.
8
 */
9
10
namespace Rafrsr\LibArray2Object\Tests\Matcher;
11
12
use Rafrsr\LibArray2Object\Matcher\LevenshteinMatcher;
13
14
class LevenshteinMatcherTest extends PropertyMatcherTester
15
{
16
17
    /**
18
     * @inheritDoc
19
     */
20
    public function buildMatcher()
21
    {
22
        return new LevenshteinMatcher();
23
    }
24
25
    /**
26
     * @inheritDoc
27
     */
28
    public function getEquals()
29
    {
30
        return [
31
            'test' => 'Test',
32
            'test_property' => 'TestProperty',
33
            'test_properti' => 'TestProperty',
34
            'testing' => 'test_ng'
35
        ];
36
    }
37
38
    /**
39
     * @inheritDoc
40
     */
41
    public function getNotEquals()
42
    {
43
        return [
44
            'testing' => 'test',
45
            'test_prop' => 'test_node',
46
        ];
47
    }
48
}
49