Completed
Push — master ( 1008a1...9cabe1 )
by Tobias
01:30
created

LocoProjectTest   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 4
lcom 1
cbo 2
dl 0
loc 28
ccs 12
cts 12
cp 1
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A setUp() 0 4 1
A testGetName() 0 4 1
A testGetApiKey() 0 4 1
A testGetIndexParameter() 0 4 1
1
<?php
2
3
namespace Translation\PlatformAdapter\Loco\Tests\Unit\Model;
4
5
use PHPUnit\Framework\TestCase;
6
use Translation\PlatformAdapter\Loco\Model\LocoProject;
7
8
class LocoProjectTest extends TestCase
9
{
10
    /**
11
     * @var LocoProject
12
     */
13
    private $locoProject;
14
15 3
    public function setUp()
16
    {
17 3
        $this->locoProject = new LocoProject('domain', ['api_key' => 'test', 'index_parameter' => 'text']);
18 3
    }
19
20 1
    public function testGetName()
21
    {
22 1
        $this->assertEquals('domain', $this->locoProject->getName());
23 1
    }
24
25 1
    public function testGetApiKey()
26
    {
27 1
        $this->assertEquals('test', $this->locoProject->getApiKey());
28 1
    }
29
30 1
    public function testGetIndexParameter()
31
    {
32 1
        $this->assertEquals('text', $this->locoProject->getIndexParameter());
33 1
    }
34
35
}
36