Passed
Pull Request — master (#376)
by Wilmer
05:03 queued 02:33
created

BetweenConditionTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A testConstructor() 0 7 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Db\Tests\QueryBuilder\Conditions;
6
7
use PHPUnit\Framework\TestCase;
8
use Yiisoft\Db\QueryBuilder\Conditions\BetweenCondition;
9
10
/**
11
 * @group db
12
 */
13
final class BetweenConditionTest extends TestCase
14
{
15
    public function testConstructor(): void
16
    {
17
        $condition = new BetweenCondition('date', 'BETWEEN', 1, 2);
18
        $this->assertSame('date', $condition->getColumn());
19
        $this->assertSame('BETWEEN', $condition->getOperator());
20
        $this->assertSame(1, $condition->getIntervalStart());
21
        $this->assertSame(2, $condition->getIntervalEnd());
22
    }
23
}
24