Skip to content

Commit

Permalink
PHPUnit 10 fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
aik099 committed Jul 8, 2024
1 parent 124e2fb commit 4afb5e3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/CodeInsight/KnowledgeBase/DatabaseManagerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,15 @@
use ConsoleHelpers\CodeInsight\KnowledgeBase\DatabaseManager;
use Prophecy\Prophecy\ObjectProphecy;
use Tests\ConsoleHelpers\ConsoleKit\WorkingDirectoryAwareTestCase;
use Yoast\PHPUnitPolyfills\Polyfills\AssertionRenames;
use ConsoleHelpers\DatabaseMigration\MigrationManager;
use ConsoleHelpers\DatabaseMigration\MigrationContext;

class DatabaseManagerTest extends WorkingDirectoryAwareTestCase
{

use AssertionRenames;

/**
* Working directory.
*
Expand Down Expand Up @@ -67,7 +70,7 @@ public function testCreatingDatabase()
$database = $database_manager->getDatabase('/absolute/path');

$this->assertFileExists($this->workingDirectory . '/databases/absolute/path');
$this->assertFileNotExists($this->workingDirectory . '/databases/absolute/path/code_insight.sqlite');
$this->assertFileDoesNotExist($this->workingDirectory . '/databases/absolute/path/code_insight.sqlite');
$this->assertEquals(
'sqlite:' . $this->workingDirectory . '/databases/absolute/path/code_insight.sqlite',
$this->getDSN($database)
Expand All @@ -80,7 +83,7 @@ public function testCreatingForkedDatabaseFromNothing()
$database = $database_manager->getDatabase('/absolute/path', 'fork');

$this->assertFileExists($this->workingDirectory . '/databases/absolute/path');
$this->assertFileNotExists($this->workingDirectory . '/databases/absolute/path/code_insight-fork.sqlite');
$this->assertFileDoesNotExist($this->workingDirectory . '/databases/absolute/path/code_insight-fork.sqlite');
$this->assertEquals(
'sqlite:' . $this->workingDirectory . '/databases/absolute/path/code_insight-fork.sqlite',
$this->getDSN($database)
Expand Down

0 comments on commit 4afb5e3

Please sign in to comment.