Passed
Pull Request — master (#396)
by Wilmer
02:32
created

CommandProvider::upsert()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 5
rs 10
c 1
b 0
f 0
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 batchInsertSql(): array
14
    {
15
        $baseCommandProvider = new BaseCommandProvider();
16
17
        return $baseCommandProvider->batchInsertSql($this->getConnection());
18
    }
19
20
    public function bindParamsNonWhere(): array
21
    {
22
        $baseCommandProvider = new BaseCommandProvider();
23
24
        return $baseCommandProvider->bindParamsNonWhere();
25
    }
26
27
    public function createIndex(): array
28
    {
29
        $baseCommandProvider = new BaseCommandProvider();
30
31
        return $baseCommandProvider->createIndex($this->getConnection());
32
    }
33
34
    public function invalidSelectColumns(): array
35
    {
36
        $baseCommandProvider = new BaseCommandProvider();
37
38
        return $baseCommandProvider->invalidSelectColumns();
39
    }
40
41
    public function rawSql(): array
42
    {
43
        $commandProvider = new BaseCommandProvider();
44
45
        return $commandProvider->rawSql();
46
    }
47
48
    public function update(): array
49
    {
50
        $commandProvider = new BaseCommandProvider();
51
52
        return $commandProvider->update($this->getConnection());
53
    }
54
55
    public function upsert(): array
56
    {
57
        $commandProvider = new BaseCommandProvider();
58
59
        return $commandProvider->upsert($this->getConnection());
60
    }
61
}
62