mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-28 17:02:04 +03:00
Performed fixes for failing tests on php8
- Commands that run a truncate DB action failed due to messing up the test transations so we mnaully work around that now to ensure a transaction exists for the test to cleanup afterwards. - Updated dompdf lib version
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
<?php namespace Tests\Commands;
|
||||
|
||||
use BookStack\Entities\Models\Page;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ClearViewsCommandTest extends TestCase
|
||||
@ -19,7 +20,9 @@ class ClearViewsCommandTest extends TestCase
|
||||
'views' => 1
|
||||
]);
|
||||
|
||||
DB::rollBack();
|
||||
$exitCode = \Artisan::call('bookstack:clear-views');
|
||||
DB::beginTransaction();
|
||||
$this->assertTrue($exitCode === 0, 'Command executed successfully');
|
||||
|
||||
$this->assertDatabaseMissing('views', [
|
||||
|
Reference in New Issue
Block a user