Passed
Push — master ( 8807b4...37e483 )
by Wilmer
03:08
created

CommandProvider   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 10
dl 0
loc 30
rs 10
c 1
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A upsert() 0 5 1
A rawSql() 0 5 1
A createIndex() 0 5 1
A update() 0 5 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Db\Tests\Provider;
6
7
use Yiisoft\Db\Tests\Support\TestTrait;
8
9
final class CommandProvider
10
{
11
    use TestTrait;
12
13
    public function createIndex(): array
14
    {
15
        $baseCommandProvider = new BaseCommandProvider();
16
17
        return $baseCommandProvider->createIndex($this->getConnection());
18
    }
19
20
    public function rawSql(): array
21
    {
22
        $commandProvider = new BaseCommandProvider();
23
24
        return $commandProvider->rawSql();
25
    }
26
27
    public function update(): array
28
    {
29
        $commandProvider = new BaseCommandProvider();
30
31
        return $commandProvider->update($this->getConnection());
32
    }
33
34
    public function upsert(): array
35
    {
36
        $commandProvider = new BaseCommandProvider();
37
38
        return $commandProvider->upsert($this->getConnection());
39
    }
40
}
41