Skip to content

Commit

Permalink
Improve test
Browse files Browse the repository at this point in the history
  • Loading branch information
Tigrov committed Jun 23, 2024
1 parent 03e05ba commit b737ff1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/ActiveQueryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
use Yiisoft\ActiveRecord\Tests\Support\Assert;
use Yiisoft\ActiveRecord\Tests\Support\DbHelper;
use Yiisoft\Db\Command\AbstractCommand;
use Yiisoft\Db\Connection\ConnectionInterface;
use Yiisoft\Db\Exception\Exception;
use Yiisoft\Db\Exception\InvalidArgumentException;
use Yiisoft\Db\Exception\InvalidCallException;
Expand Down Expand Up @@ -2686,7 +2687,7 @@ public function testARClassAsInstance(): void

public function testARClassAsClosure(): void
{
$closure = fn () => new Customer($this->db);
$closure = fn (ConnectionInterface $db): Customer => new Customer($db);
$query = new ActiveQuery($closure, $this->db);

$this->assertSame($query->getARClass(), $closure);
Expand Down

0 comments on commit b737ff1

Please sign in to comment.