Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
vjik committed Jan 16, 2024
1 parent 0165607 commit 995d12a
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/Reader/Filter/CompareTest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?php

declare(strict_types=1);

namespace Yiisoft\Data\Tests\Reader\Filter;

use PHPUnit\Framework\TestCase;
use Yiisoft\Data\Reader\Filter\LessThan;

final class CompareTest extends TestCase
{
public function testWithValue()
{
$filter = new LessThan('field', 1);

$this->assertNotSame($filter, $filter->withValue(1));
$this->assertSame(['<', 'field', 2], $filter->withValue(2)->toCriteriaArray());
}
}

0 comments on commit 995d12a

Please sign in to comment.